Hi Pablo.Pablo César wrote:Hi dear Claudio,
In MAIN ON INIT it is calling InstallEventHandler with just one parameter. It is a interesting new function you have created at h_windows.prg. And I wish to add at least one parameter and if possible: two.
Because in your SplitChildWindow_ON_PAINT function, forms parameters ("Win1" and "SplitChild_1") are fixed and I would like to let it in variables way. The most strange (at least for me), this SplitChildWindow_ON_PAINT function received these arguments:
SplitChildWindow_ON_PAINT(hWnd, nMsg, wParam, lParam)
So I would like to understand this function call and I would like your help to adapt with forms variables (if is it possible, of course).
Thanks, Dr. Soto for your attention.
1) InstallEventHandler is a native function of HMG that accepts only one paramatro: the name of the function to call.
2) The function registered with InstallEventHandler should always have the following parameters: ( hWnd, nMsg, wParam, lParam )
These parameters are the same with that the system communicates with the procedures that manipulate the windows.
In this function you process the system message.
3) I developed a way more easy:
Code: Select all
SPLITCHILD WINDOW <cForm> OF <cParent> ON PAINT <OnPaintProcedure>