Blocking Alt+F4

Maviee

New Member
Hi,

I have a rather strange problem, but I have to use tough means to force a person to klick on a button.

Lets say I have a (smart)window. I deleted the menu, the close, minimize, maximize buttons, it doesn't appear in the task bar. Everything alright so far. But the user is still able to close the window by pressing ALT+F4, which is not supposed to happen. Clever as I am :rolleyes: added a trigger for the ALT+F4 event. Works cool so far, the programm doesn't close ... once. When I press ALT+F4 again, the window will close.

So my question is: Is it possible to block certain keyboard events completly? I know how to do it in C++, but sadly Progress is another topic :(

Hope you can help me. Thanks in advance!

Greetings
Mav
 
could be

why dont you try to put a kind of flag for the action you want to do, and then on the windows-close event yuo can check that and if the user did not do the action and pressed Alt+F4 you con know it.
Good luck
 
Will not work.
Alt+F4 is a M$ Windows action. It is the default method to close the open window. Much like CTL+C (Copy) / CTL+V (moVe). The Progress OpenEdge 4GL sits onTop of the OS (Windows)
 
lord, never say never

btw, you can also disable ctrl-c



<snippet>

view current-window.

do on endkey undo, retry: /* traps the endkey condition */

wait-for "go" of current-window.

end. /* do on endkey */

</snippet>



alt-f4 raises the endkey condition, like, esc

and aborts the current block.

here's an example -



<snippet>

view current-window.

repeat:

wait-for "go" of current-window.

end. /* repeat */

message "hello" view-as alert-box.

</snippet>
 
actual

RE:
lord, never say never
>>
I did not say never. There are obviousley work arounds - it is M$ Windows and no 1 way is correct or limited.
 
M$

Joey dude,

RE:
alt-f4 raises the endkey condition, like, esc

>>My point exactly you are NOT using a default trigger, like with most of the brown stuff that is called Windows. You are using work arounds. The ALT-F4 event (close current dialog event) is NOT being used, it has been assigned the event END-ERROR.
Messy brown stuff by M$.
 
you don't have to prove anything.


how is that a work around ?

it's a condition and that's how you handle a condition


how is it windows fault ? it's progress default behaviour

and what's so great about the progress "win95" gui ?
 
Back
Top