I was looking at the serial port sample from PowerBASIC Inc and noticed several callback functions in use:
I was surprised because only one of them is associated with the dialog. The others are simply called like any other function. Also, the extra callback functions use CB.HNDL (but none of the other CB statements).
I didn't know you could use a callback not tied to a dialog/control, nor did I know that an "un-tied" callback would be given the CB values - but from which message? And suppose there were 2 dialogs in the apps, what would CB.hndl return?
Can someone clarify why/how a Callback is used in this fashion?
Code:
CallBack Function Dialog_Callback () As Long CallBack Function Send_Callback () As Long CallBack Function SendFile_Callback() As Long CallBack Function ReceiveFile_Callback () As Long CallBack Function Quit_Callback () As Long
I didn't know you could use a callback not tied to a dialog/control, nor did I know that an "un-tied" callback would be given the CB values - but from which message? And suppose there were 2 dialogs in the apps, what would CB.hndl return?
Can someone clarify why/how a Callback is used in this fashion?
Comment