Using Function keys with toggle buttons

M

Martin

Hi,

Is it possible to use the function keys to activate a
certain toggle button on a form.

What coding do I need to do?

I always thought it was the sendkeys command but I could
be wrong.

Any help greatly appreciated.

Martin
 
T

Tim Ferguson

Is it possible to use the function keys to activate a
certain toggle button on a form.

What coding do I need to do?

I think it's Form.KeyPreview = True and then trapping the Form_KeyPress or
KeyDown event. But I don't often do this!

An alternative is to use the Autokeys macro: see help.
I always thought it was the sendkeys command but I could
be wrong.

No: SendKeys is a way to simulate keypresses in another application and is
often (ahem) unsuccessful.

HTH


Tim F
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top