martjah Posted September 11, 2006 Share Posted September 11, 2006 (edited) hello, i'm making a little script for updating a speedtouch router. i have the following script: Opt("TrayIconHide", 0) Opt("WinWaitDelay", 1) Opt("WinTitleMatchMode", 2) $oRofl = "cmd.exe" Run(@ComSpec & " /c " & 'ftp 192.168.1.254', "", @SW_SHOW) WinWaitActive($oRofl) Sleep(500) ControlSend("cmd.exe", "", "", "Administrator{enter}") WinWaitActive($oRofl) sleep(500) ControlSend("cmd.exe", "", "", "{ENTER}") it's starts and enter the username administrator but not Administrator i need to put in a capital A otherwise the login is nog approved. i'm a newbie but i could not find the answer. Edited September 11, 2006 by martjah Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 11, 2006 Moderators Share Posted September 11, 2006 Are you asking about _StringProper()? Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
martjah Posted September 11, 2006 Author Share Posted September 11, 2006 Are you asking about _StringProper()?uhm what do u meen?i'm talking about this part: ControlSend("cmd.exe", "", "", "Administrator{enter}")in the dos box he doesnt type A but just a small ait needs to be a big A otherwise it wont login. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 11, 2006 Moderators Share Posted September 11, 2006 uhm what do u meen?i'm talking about this part: ControlSend("cmd.exe", "", "", "Administrator{enter}")in the dos box he doesnt type A but just a small ait needs to be a big A otherwise it wont login.Did you bother to look up _StringProper() in the help file? Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
martjah Posted September 11, 2006 Author Share Posted September 11, 2006 i tried it but i dont get the id. tried ControlSend("cmd.exe", "", "",_StringProper("administrator")) with spaces, without, with enter and without enter. i'm not the smartest person.... Link to comment Share on other sites More sharing options...
GaryFrost Posted September 11, 2006 Share Posted September 11, 2006 (edited) might try setting the flag to 1 so it sends in raw mode for the "Administrator" part then use a normal ControlSend for the "{ENTER}" Edited September 11, 2006 by gafrost SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
martjah Posted September 11, 2006 Author Share Posted September 11, 2006 uhm fixed in in another way Opt("TrayIconHide", 0) Opt("WinWaitDelay", 1) Opt("WinTitleMatchMode", 2) $oRofl = "cmd.exe" Run(@ComSpec & " /c " & 'ftp 192.168.1.254', "", @SW_SHOW) WinWaitActive($oRofl) Sleep(500) Send("Administrator") WinWaitActive($oRofl) sleep(100) ControlSend("cmd.exe", "", "", "{ENTER}") sleep(500) ControlSend("cmd.exe", "", "", "{ENTER}") 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