Child of a Child of a Child of a Child... Controls
Keywords:
Question:
Well, I've got the ID number (1204) of a button that happens to be a child of a child of a child of
a child of a child of a child of a child of the "3D Studio MAX" window. How do I use
cPostButton() to press this button? The following code generates the error "Specified parent
window doesn't exist":
AddExtender("wwctl34I.dll")
cMain = DllHwnd("3D Studio MAX")
cPostButton(cWndByID(cMain,1204))
Is it necessary to somehow specify some reticulate tree of controller children?
Answer:
Note: I got it working with the following code:
AddExtender("wwctl34I.dll")
cMain = DllHwnd("3D Studio MAX")
cX = cWndByClass(cMain,"EditPanel")
cX = cWndByClass(cX,"SysTabControl32")
cX = cWndByClass(cX,"DisplayTask")
cX = cWndByClass(cX,"RollupWindow")
cX = cWndByClass(cX,"GRAY")
cX = cWndByClass(cX,"RollupPanel")
cX = cWndInfo(cX,6)
cX = cWndInfo(cX,6)
cX = cWndByClass(cX,"#32770")
cX = cWndByID(cX,1204)
cPostButton(cX)
Article ID: W12494
Filename: Child of a Child of a Child... Controls.txt