ttleser Posted December 2, 2006 Share Posted December 2, 2006 I've got an interface program, called Smartlaunch, running on my computers that replaces the normal windows shell. Smartlaunch allows users to sign in and only get a menu with specific applications that they can use (no windows desktop). At any time, if you hit the Escape button on the keyboard, a window will appear asking for a admin user id and pw. I can enter that id and pw and once I click ok it'll bypass Smartlaunch and replace it with the normal windows shell, basically giving you the normal windows desktop. There is a feature with the Smartlaunch adminstrator program (running on another computer) that allows you to launch remote applications and basically perform various functions on the client computers (turn on, turn off, restart, etc..). I wrote a simple AutoIT script that'll bypass Smartlaunch when I tell the system to run the script up from my administrator program. MouseMove(100, 100); wakes up the pc if in screensaver or hibernating. Sleep(5000) Send("{ESC}"); should bring up the admin window. Sleep(2000) Send("adminusername") Sleep(1000) Send("{TAB}") Sleep(1000) Send("adminpassword") Sleep(1000) Send("{ENTER}") Sleep(2000) MouseMove(583, 458); moves mouse to the "login as admin" button. Sleep(1000) MouseClick("left"); clicks the "login as admin" button. Unfortunately the escape button isn't working as I expected. I can hit the ESC button on the keyboard and it'll bring up the bypass menu, but if I remotely run the app it doesn't. Now I know the rest of the app works, cause I can see the admin id and pw show up on the current window. For some reason the ESC isn't working. Does anyone have any other idea other than the typical Send("{ESC}")??? Link to comment Share on other sites More sharing options...
Developers Jos Posted December 2, 2006 Developers Share Posted December 2, 2006 .... but if I remotely run the app it doesn't. Now I know the rest of the app works, cause I can see the admin id and pw show up on the current window. For some reason the ESC isn't working. Does anyone have any other idea other than the typical Send("{ESC}")???Can you explain what you mean by "remotely run" ? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
ttleser Posted December 2, 2006 Author Share Posted December 2, 2006 There is a function of the administrator program running on my frontdesk computer that you can tell a remote computer to run an application. I'm not exactly sure how it works, but for example... In the Launch remote application feature you can setup a new program to run:Name:NotepadCommand: notepad.exeSwitches: (blank)Now, when I select notepad in Launch remote applications and then select computer 12 and say "launch", I can walk over to PC12 and see that notepad has run on it. Now, I can program in any application on my frontdesk computer's admin program using the path and program name and when I run it the remote computer will go out and run that program. The feature is very similiar to a program called PSTools, that allows you to launch programs on a remote computer using the command line, my Smartlaunch admin program just allows me to do the same thing graphically. Link to comment Share on other sites More sharing options...
ttleser Posted December 3, 2006 Author Share Posted December 3, 2006 Bump?? Link to comment Share on other sites More sharing options...
Bert Posted December 3, 2006 Share Posted December 3, 2006 (edited) This may sound nuts, but I did this to fix a problem like this. Do this Send("{ESC}") sleep(20) Send("{ESC}") sleep(20) Send("{ESC}") sleep(20) For some reason that escapes me, this fixed my problem. It may also fix yours. If I'm wrong, I'm wrong, but it wouldn't hurt to try it. I had a issue with copying some text to the clipboard from a application, and this was the only way could get it to work. Edited December 3, 2006 by Volly The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
ttleser Posted December 3, 2006 Author Share Posted December 3, 2006 Tried it, didn't work. Link to comment Share on other sites More sharing options...
ma123 Posted December 3, 2006 Share Posted December 3, 2006 what about trying this, i am not sure if it will work but its worth a try: HotKeySet("{ESC}", "Terminate") Func Terminate() WinKill(" insert name of window") Exit EndFunc Thats if your trying to close the window but im not sure if thats what you want to do, maybe something like this: WinActivate("") i dunno really, thats all i can think of lol When you say remotely run, do u mean controlling it by another device i.e through bluetooth or something or no? Link to comment Share on other sites More sharing options...
ttleser Posted December 4, 2006 Author Share Posted December 4, 2006 Sorry MA123, not trying to terminate a window. Esc actually brings up a window, that's what I'm trying to do. Link to comment Share on other sites More sharing options...
mikehunt114 Posted December 4, 2006 Share Posted December 4, 2006 Can you WinActivate() or ShellExecute() the application you are trying to activate? IE Dev ToolbarMSDN: InternetExplorer ObjectMSDN: HTML/DHTML Reference Guide[quote]It is surprising what a man can do when he has to, and how little most men will do when they don't have to. - Walter Linn[/quote]--------------------[font="Franklin Gothic Medium"]Post a reproducer with less than 100 lines of code.[/font] Link to comment Share on other sites More sharing options...
Joon Posted December 4, 2006 Share Posted December 4, 2006 Far as I know, you can not send a keystroke to a remote PC. If not, how about trying ControlSend to Smartlanuch window? Link to comment Share on other sites More sharing options...
1905russell Posted December 5, 2006 Share Posted December 5, 2006 (edited) Unfortunately the escape button isn't working as I expected. I can hit the ESC button on the keyboard and it'll bring up the bypass menu, but if I remotely run the app it doesn't. Now I know the rest of the app works, cause I can see the admin id and pw show up on the current window. For some reason the ESC isn't working. Does anyone have any other idea other than the typical Send("{ESC}")???Did you try?$text = Chr(27)Send($text)or justSend(Chr(27))or trySend(+Chr(27)) Edited December 5, 2006 by 1905russell Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now