Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SEND KEYS and Locked Computer

Status
Not open for further replies.

MacroManII

Programmer
Nov 14, 2002
22
US
Hi,

I have a program that when it runs it runs a .bat file
which needs a parameter passed to it. I am using send keys
to do this very successfully, except when the Windows Security is activated and my system is locked. The program is on a schedule and activates at 7am, but when I come to work at 8am the screen is locked and when I press Alt Ctrl + Del and enter my network password the processing is hanging where the parameter should have been sent by the send keys.

Any help ?

MacroManII
 
Instead of using sendkeys to pass parameters you could create another .bat file that calls your original one and passes it the parameters normally, or you could use windows scripting to call the .bat file.

Tracy Dryden

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard. [dragon]
 
Tracy,

The first bat file calls a program, which when it runs it prompts for a parameter. I do not see how having two bat files will help the situation

Regards

Still need help ...

 
it runs a .bat file which needs a parameter passed to it

You didn't say anything about a prompt, that changes things considerably. I've never had much success using SendKeys. Check into windows scripting and see it it gives you a way to handle the prompt. You can use the windows scripting object within a VB program.

Tracy Dryden

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard. [dragon]
 
Easy just stop your computer from locking :) ok now seriously send keys are bad. I think there are tools to log you in or wake your pc up.. get one and have it wake the pc up at 6:55 so at 7 your pc will be able to accept the commands given. Other then that i dont know im sorry :(

Running in circles is what I do best!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top