Sendkeys Alternatives

  • Thread starter Thread starter Ray Hogan
  • Start date Start date
R

Ray Hogan

Hi,
What are the alternatives/workarounds for the following "Sendkeys" actions.
1) "{ENTER}"
2) "{TAB}"
Thanks in anticipation.
Rayh
 
Hi,
Just two examples;
1) Senkeys "^{TAB}" to move from SubForm

2) DoCmd.Runcommand acCmdCopy
Sendkeys "{ENTER}

Regards.
Rayh
 
1) can't you just set the focus to the main form?
2) docmd.RunCommand accmdcopy
I think there are more robust options than using sendkeys.
 
Hi,
Just two examples;
1) Senkeys "^{TAB}" to move from SubForm
Parent.SetFocus
Parent.controlname.SetFocus

2) DoCmd.Runcommand acCmdCopy
Sendkeys "{ENTER}

If you're copying the contents of one control to another control,
don't use acCmdCopy; just set the value of the control.
 

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

Similar Threads

SendKeys with enter 1
ActiveX 1
Running unix(putty) commands from vba 1
argh... SendKeys hell 14
Command Button on Report 1
Form AfterUpdate 2
SetValue 5
Using the find action 1

Back
Top