FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour ESC key blanks out MDI Child dialog
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
ESC key blanks out MDI Child dialog
Posted: Wed Sep 21, 2011 09:20 PM
To ALL

I have a dialog embedded within a mdi child and when you hit the escape key .. the dialog box disappears and leaves a grey mdi child frame.

This has bothered me for some time but it rarely ever cropped up in production. Just curious if anyone has found a work around ( other than turning off the escape key ) to knit both the dialog to the mdi frame together .. so that either nothing would happen or the escape key could trip a valid close ?

Thanks
Rick Lipkin

ps .. I have tried this code with the same results where oWnd1 is the mdi child:

Code (fw): Select all Collapse
// key handler to trap key strokes  ESC to quit  //
       oWnd1:bKeyDown := {|nKey| IF(nKEY = 27, oWnd1:END(), ) }






Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Re: ESC key blanks out MDI Child dialog
Posted: Wed Sep 21, 2011 09:25 PM
Code (fw): Select all Collapse
VALID !GETKEYSTATE( K_ESC )


EMG
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
Re: ESC key blanks out MDI Child dialog
Posted: Thu Sep 22, 2011 01:00 PM

Enrico

Thank you .. I plugged your solution into the valid clause on the activate dialog line and it worked ..

Many Thanks
Rick

Continue the discussion