Link to home
Start Free TrialLog in
Avatar of Wee_Pecky
Wee_PeckyFlag for New Zealand

asked on

Is there a SHIFTDOWN in VB.NET for the SendKeys.SendWait method ?

Hi,

Is there a VB.NET parameter for the SendKeys.SendWait function which will press the shift key down and keep it down until released by another SendKeys call?

I cannot seem to find the .NET way of sending {SHIFTDOWN} or {SHIFTUP}.

TIA.
Wee.
Avatar of iboutchkine
iboutchkine

I believe send shift willbe

Sendkeys.Send("+{END}") ' Shift+End

Sending keystrokes is *very*
unreliable, and usually bad programming practice
Avatar of Mike Tomlinson
"and keep it down until released by another SendKeys call?"

No.  With SendKeys there isn't any way to KEEP it down until you specify it be released.

To do that you would need to use Win APIs...
Avatar of Wee_Pecky

ASKER

Thanks your comments, I understand sendkeys is dubious coding practice.
Can you suggest another method of ensuring an access database does not launch its opening code when opened by OPENDATABASE method?
No, but the solution to this problem can be found here:

http://blogs.msdn.com/robgruen/archive/2004/04/15/114020.aspx

The code will need tweeking to get a shiftdown experience but it is easy enough to do.
ASKER CERTIFIED SOLUTION
Avatar of Wee_Pecky
Wee_Pecky
Flag of New Zealand image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial