Jump to content

ControlSend to Firefox


czmaster
 Share

Recommended Posts

Hello,
 
When I use a specific hotkey (with HotKeySet) I want to send a specific text in the active windows.

Example :

HotKeySet("^+e","ex")
func ex()
ControlSend("","","","ex")
EndFunc

I don't just use Send because If I send a letter while pressing CTRL (used in my hotkey) it will not work, so i used ControlSend

This code works very well in all programs except Firefox
Do you know why ?
 
Thank you

 

Link to comment
Share on other sites

most likely you mean you are in an html page and as such it will not recognize the control to activate first

suggestion to use send but before put a sleep 500 or something like that so you have a short moment to release your ctrl key

other suggestion can be to check first if ctrl key is down before sending input with GetAsyncKeyState

Edited by junkew
Link to comment
Share on other sites

Thank you for the answer
Since I tried to change the hotkey with F10 (for example) and it works in firefox
So the problem is that Firefox does not appreciate when it use the ALT or CTRL hotkeys with ControlSend
Against Send works well with , but it does not work in other software like Ms Word

 

I will investigate this case

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...