Skip to content

Instantly share code, notes, and snippets.

@sidola
Last active August 29, 2015 14:04
Show Gist options
  • Save sidola/58dc1a11d274886359a7 to your computer and use it in GitHub Desktop.
Save sidola/58dc1a11d274886359a7 to your computer and use it in GitHub Desktop.
AHK - Sets a GUI as a child to a parent, via parent class
SetParentByClass(Window_Class, Gui_Number) ; F
{
Parent_Handle := DllCall( "FindWindowEx", "uint",0, "uint",0, "str", Window_Class, "uint",0)
Gui, %Gui_Number%: +LastFound
Return DllCall( "SetParent", "uint", WinExist(), "uint", Parent_Handle )
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment