Topic: KEY CODES
Hello MVD
Can I ask a sample on enabling button using key codes via script?
Thanks!
My Visual Database → General → KEY CODES
Hello MVD
Can I ask a sample on enabling button using key codes via script?
Thanks!
Hello.
Unfortunately can't understand the question, please provide more details.
Hello.
Unfortunately can't understand the question, please provide more details.
----------------------------------
I have a button in the form in which i set it in the properties enable=false. Once i run the project the button must be disabled and that is correct. Now I want it enable using the a key codes or any combination of codes.
Pls give a sample!
Thanks!
I estimate that is is looking for something to catch the keyboard buffer directly like the
cin
command from C++.
Getting directly the information what keys have been pressed on the keyboard to initiate an action regardsless which field has the focus and is active.
I estimate that is is looking for something to catch the keyboard buffer directly like the
cin
command from C++.Getting directly the information what keys have been pressed on the keyboard to initiate an action regardsless which field has the focus and is active.
---------------------
let say ctrl+home
Example for Ctrl+1
procedure Form1_OnKeyUp (Sender: string; var Key: Word; Shift, Alt, Ctrl: boolean);
begin
if (Ctrl) and (Key=ord('1')) then Form1.Button1.Enabled := True;
end;
begin
Form1.KeyPreview := True;
end.
Example for Ctrl+1
procedure Form1_OnKeyUp (Sender: string; var Key: Word; Shift, Alt, Ctrl: boolean); begin if (Ctrl) and (Key=ord('1')) then Form1.Button1.Enabled := True; end; begin Form1.KeyPreview := True; end.
=========
I got it!
Thanks Sir !
My Visual Database → General → KEY CODES
Powered by PunBB, supported by Informer Technologies, Inc.
Theme Hydrogen by Kushi