I would like someone to confirm whether Valid will work with a Dialog or NOT. In my case VALID statement is not getting executed while I try to close the Dialog but it is working fine if i define the window as MDICHILD
- Code: Select all Expand view
DEFINE DIALOG oDlg TITLE "Account Heads"
@ 0, 0 XBROWSE oBrw LINES CELL;
COLUMNS 'ACCODE','NAME','GRCODE' ;
SIZE 370,oDlg:nHeight-35 PIXEL ;
OF oDlg ;
ALIAS 'AcMaster_ACM'
ACTIVATE WINDOW oDlg ;
on INIT oBrw:SetFocus();
VALID MsgYesNo( "Do you want to quit Ac Heads ?","Quit AC Head")
If I try to define the window as Window of wndMain() then there is no title bar and close button for that particular window.
From where can I get more information on the behaviors of different type of windows ? Advantage of Defining a window as "DEFINE Window oWnd of wndMain()"
In case of a DIALOG, to execute a set of instructions after the user close the Dialog, I assume that the statements should be given after the ACTIVATE window instead of using the VALID clause. Am I right ?
I understand that in case of a DIALOG the execution of the PRG pauses till the user close the DIALOG. But in case of other type of Windows, program execution does not pause like a DAILOG ie the next statement after ACTIVATE Window will be executed immediately after displaying the Window. So accordingly you have to write the code based on what type of window you are going to use.
wndMain() works like a DIALOG. The execution of PRG statements pauses till the user close the Main Window ie the statements after ACTIVATE window will get executed only after the user close the Main Window. Ideal for closing the opened DBF files
Friends, correct me if I am wrong.
If the above info is right then it may be useful to new FWH developers like me.
Regards
Anser