...

View Full Version : How to emulate keypress on mouse click?



george2012
05-16-2012, 08:03 PM
I've spent days searching without luck.
I need help with the following:

I have a program that have some hotkeys set to trigger some events. I would like to activate those hotkeys from inside firefox by clicking on a button. I'm not looking for keypress events, it has to be a button click.
So, let's say I click on the button that executes a javascript code that emulates F7 or CTRL+A or whatever key or key combination. Can you guys please help with to find a solution?
Oh, and I need it to work with Firefox only.

Thanks!

Philip M
05-16-2012, 08:54 PM
I've spent days searching without luck.
I need help with the following:

I have a program that have some hotkeys set to trigger some events. I would like to activate those hotkeys from inside firefox by clicking on a button. I'm not looking for keypress events, it has to be a button click.
So, let's say I click on the button that executes a javascript code that emulates F7 or CTRL+A or whatever key or key combination. Can you guys please help with to find a solution?
Oh, and I need it to work with Firefox only.

Thanks!

Not possible. You cannot emulate a key press. Javascript cannot access the operating system or the Windows registry, nor alter the default behaviour of the browser.


All advice is supplied packaged by intellectual weight, and not by volume. Contents may settle slightly in transit.

george2012
05-17-2012, 07:25 AM
Thank you for the answer!



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum