Jump to content

How can I?


Lakesat
 Share

Recommended Posts

I'm automating net use command and it's working fine for most case but...

E.g.:

Send("net use \\" & $ProjectIP & "\ipc$ " & $Password & " /user:" & $Domain & "\administrator")

Cases that aren't working are those that contains symbols in the password like "#"... Look like Autoit isn't seeing it as "string"

Is there a way to input my password this way and make sure all caracters will be recognized?

Louis Vigneault

Link to comment
Share on other sites

Hi,

Use Chr....

$text = ""

For $i = 65 to 90

$text = $text & Chr($i)

Next

MsgBox(0, "Uppercase alphabet", $text

Andre

What about Windows without using AutoIt ?It would be the same as driving a car without an steering Wheel!
Link to comment
Share on other sites

I can't really use Chr, because i'm reading the password from an ini file and special character are not always at the same position (password of 10 char), I have 32 password in it, and i might get more. is there a way to make what I read a complete recognizable string?

Link to comment
Share on other sites

RTFM, Faq 10

...

Ok, I am so evil to leave with only wrote that 12 chars. But... READ THE MANUAL!

Solution:

The command send, see some chars as special character for combinations, e.g. !{F4} means ALT+F4 not writing ! { F 4 and }

When you are using Send with variants it is a good idea use the RAW mode that always send the keys 'as they are wrote' so !{F4} indeed means ! { F 4 and }. Since you can't know if the variant will keep special chars or not.

Your command:

Send("net use \\" & $ProjectIP & "\ipc$ " & $Password & _
" /user:" & $Domain & "\administrator",1)

Just for your knowledge the # means the Win key... :ph34r:

Did I mentioned to read the manual?

Edited by ezzetabi
Link to comment
Share on other sites

RTFM, Faq 10

...

Ok, I am so evil to leave with only wrote that 12 chars. But... READ THE MANUAL!

Solution:

The command send, see some chars as special character for combinations, e.g. !{F4} means ALT+F4 not writing ! { F 4 and }

When you are using Send with variants it is a good idea use the RAW mode that always send the keys 'as they are wrote' so !{F4} indeed means ! { F 4 and }. Since you can't know if the variant will keep special chars or not.

Your command:

Send("net use \\" & $ProjectIP & "\ipc$ " & $Password & _
" /user:" & $Domain & "\administrator",1)

Just for your knowledge the # means the Win key...  :ph34r:

Did I mentioned to read the manual?

<{POST_SNAPBACK}>

Ouch!!

Sorry about this one, should have look at the manual first (well, i've read it like 2-3 weeks ago and didn't remebered this info). Next time i'll look carefully before posting here...

Thanks for leading me to the answer, I appreciate :(

Louis Vigneault

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...