|
Previous Top Next |
Prototype: | (LONG pSourceControl, LONG pDestinationControl, BYTE pMatchPosition = FALSE) |
pSourceControl | Control to copy size from |
pDestinationControl | Control to copy size to |
pMatchPosition | Indicates if the destination control should be moved to the position of the source control. Defaults to FALSE. |
This method sets the size and optionally the position of the destination control to match the size and position of the source control. Comes in handy when you need to stack controls at runtime but would like to keep them separated at design time.
Example:
Window WINDOW('MatchControlSize'),AT(,,257,98)
BOX,AT(14,8,47,40),USE(?BOX1),COLOR(COLOR:Black),FILL(COLOR:Black),LINEWIDTH(1)
REGION,AT(85,25),USE(?REGION1)
END
ITC ITCoreClass
CODE
OPEN(Window)
ITC.MatchControlSize(?BOX1,?REGION1,TRUE)
ACCEPT
END
CLOSE(Window)
See also: