Control_OnKeyPress(Key)

2 keys

hello.
I dont find.
How to use 2 keys with the method Control_OnKeyPress(Key)
I need crtl+C

Sub Control_OnKeyPress(Key)
If Key = Ctrl+c Then
DesktopX.ScriptObject("wiki_browser")......
End If
Thank you.
5,786 views 4 replies
Reply #1 Top
Please look at the DX documentation:

OnKeyPress(key): Fired when a key is entered, returns the ASCII value of the key.

You may use this method to type/enter the text but you may not use it to get/send a code of special keys like Alt, Ctrl, etc... More over for two keys which pressed together.

Now look at the System.Clipboard and System.KeyState(key) methods. This may really help you.
Reply #2 Top
good day.
thank you for answer.
but...I dont think that it is that
I am trying to create a web browser.I have a textbox with 3 buttons= 3 link (URL+'word in textbox').
I try to create 3 keyboard shotcut towards these URL via my web browser.
I dont find the method has to use.
good bye.
Reply #3 Top
Do you mean hotkeys to activate an function even when the object hasn't got any focus? In which case you'd want to use Object.RegisterHotkey

But if it's for shortcuts within an application (your widget) only then you'd need to do what Vad_M said.
Reply #4 Top
hello and thank you, but...
It is too complicated for me.  
I would see that the next year,when I would understand the vbscript.  
I use the event keydown with the keys F1, F2, F3. it is simpler

soon a new question...

bye.