Page 1 of 1

don't close window with Escape

PostPosted: Fri Nov 26, 2021 2:08 pm
by plantenkennis
Hello,
It has been a long time since I had the oppurtunity to work on my program, due to personal problems.
I have some questions:
When in the Window definition I don't use the VALID option, the user can close the Window with the Escape key. I have set a VALID in this way:
Code: Select all  Expand view

VALID ( IF(MsgYesNo('Want to end?'), (RK_SaveVariables(), RK_CloseTables()), )
 

But if the user clicks 'No' the program still stops. How can I make it that the program respons to the 'No' choise?

Re: don't close window with Escape

PostPosted: Fri Nov 26, 2021 2:31 pm
by cnavarro
Hello, try with
Code: Select all  Expand view

VALID ( IF(MsgYesNo('Want to end?'), (RK_SaveVariables(), RK_CloseTables(), .T. ), .F. ) )
 

Re: don't close window with Escape

PostPosted: Sun Nov 28, 2021 11:05 am
by plantenkennis
Hello,

Thank you very much, that was the trick :D