HelpPath{Create}CommandName{createGadgetFromWindow}ReturnValue{int handle=}OpenBrace{(}Parameters{handle window}CloseBrace{)}Description{Wraps an existing window created by another program into a gadget so that you can interact with it using the other gadget commands.  For example, if you wanted to set the title of the main DBPro window, you would do this:<br><br>
main=createGadgetFromWindow(mainWindow())<br>
setGadgetText main,"New Title"<br>}ReturnDescription{Handle to the new gadget}Param1{window}Param1Desc{Handle to the window which is to be wrapped as a gadget.  This is *not* a gadget handle.  Windows documentation refers to this kind of handle as an HWND.}Param2{}Param2Desc{}Param3{}Param3Desc{}Param4{}Param4Desc{}Param5{}Param5Desc{}Param6{}Param6Desc{}Remarks{It is faster to use one call to setGadget than seperate calls to resizeGadget and moveGadget.}Param7{}Param7Desc{}ExampleSource{}SeeAlso{}Param8{createTopMost}Param8Desc{If 1, the window is created independant of all the other windows in your program, if 0 the window is created as a child of another gadget, as specified by the parent parameter.}Param9{parent}Param9Desc{Handle to the parent for the new gadget.  If 0, this is either the main DBPro window if createTopMost is 0, or the window has no parent (if createTopMost is 1)}