|
Previous Top Next |
Prototype: | (Long phWnd),Long |
phWnd | Window handle to enumerate child windows for, i.e. parent window |
Returns | Number of child windows |
This method is used to enumerate all child windows of a parent window specified in the phWnd parameter. Please note that this does not enumerate non-MDI windows that have been opened by the appframe if the appframe handle is the phWnd passed to this method. It will only enumerate MDI windows. Also note that all controls are considered child windows.
Example:
ITW ITWindowsClass
Code
SetupWindow ROUTINE
Data
I Long
Code
If ITW.EnumChildWin(pParentHandle)
Loop I = 1 To Records(ITW.ChildWindows)
Get(ITW.ChildWindows,I)
ChildWindows.CW:CwHwnd = ITW.ChildWindows.CwHwnd
ChildWindows.CW:Style = ITW.ChildWindows.Style
ChildWindows.CW:ExStyle = ITW.ChildWindows.ExStyle
ChildWindows.CW:Text = ITW.ChildWindows.Text
Add(ChildWindows)
End
End
Please refer to the Example Program TestEnumChildWindows procedure for examples of implementation.
See also: