Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Numlock key & Access macros

Posted on 2000-04-13
9
Medium Priority
?
536 Views
Last Modified: 2012-05-05
I have a macro tied to a field that sends few keystrokes to the form using the sendkeys Access command.

But as soon as the macro fires, it turns off my numlock key. Even sending a numlock at the end of the macro doesn't turn it back on. Help !

Is there a command or some VB code I can use to turn it back on ?
0
Comment
Question by:munna
  • 3
  • 2
  • 2
  • +1
9 Comments
 

Author Comment

by:munna
ID: 2712895
NC
0
 
LVL 9

Expert Comment

by:BrianWren
ID: 2712965
This is a known bug with Access, which is documented at MS's web site.

To work around this, find another way to accomplish your goal.  (This can almost always be done.)

Can I help?

Brian
0
 

Expert Comment

by:GOLLEM
ID: 2712980
munna->

What exactly are you sending? Maybe you're using the wrong combination of letters. This is a really weird problem......

Have you checked yet if the same problem occurs on a different machine? The problem could also be in your access installation.

I'm listening in anyway, this is interresting :)

Regards,

         Michiel

0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 9

Expert Comment

by:BrianWren
ID: 2713074
Michiel, it is a known bug....
0
 
LVL 9

Expert Comment

by:BrianWren
ID: 2713107
The more I think on it, the more I seem to remember that using DoEvents after SendKeys is supposed to help...  (This might help only in VBA.  You might need to put your SendKeys into a function that you call instead, which has DoEvents after each Sendkeys instruction.

Brian
0
 
LVL 7

Expert Comment

by:Believer
ID: 2713301
[In the tone of voice of Beavis & Butthead...]  "Sendkeys suck, heh. heh. heh..." "Yeah, heh, so do macros, heh.  heh."  
Sorry, I'm feeling a bit... opinionated!!!
0
 

Author Comment

by:munna
ID: 2713762
I am basically sending few TABs to jump to a subform and then CTRL+SHIFT+TAB to jump back to the mainform. I am doing this so that the user will not exit the data entry screen without creating atleast one record on the subform. If you can tell me what command I can use to do that with code, it will be great.
I am not at all an experienced programmer (as you can tell).



0
 
LVL 7

Accepted Solution

by:
Believer earned 300 total points
ID: 2713820
You could pursue the Macro command GoToControl.  If you write code beind the form instead of a macro, look into the .SetFocus property of controls instead.
0
 

Expert Comment

by:GOLLEM
ID: 2713998
Brian->

Hadn't noticed that bug yet :)

0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.
Suggested Courses

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question