Jump to content
Sign in to follow this  
martjah

capital?

Recommended Posts

martjah

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 by martjah

Share this post


Link to post
Share on other sites
SmOke_N

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.

Share this post


Link to post
Share on other sites
martjah

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 a

it needs to be a big A otherwise it wont login.

Share this post


Link to post
Share on other sites
SmOke_N

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 a

it 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.

Share this post


Link to post
Share on other sites
martjah

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....

Share this post


Link to post
Share on other sites
GaryFrost

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 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.

 

Share this post


Link to post
Share on other sites
martjah

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}")

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.