Jump to content

How Can I do this? RunWait(@ComSpec & ' /c


Recommended Posts

Hi. I have this:

RunWait(@ComSpec & ' /c wget --read-timeout=60 --http-user=mynick --http-password=mypass "http://192.168.0.1/wizard.htm"', "", @SW_HIDE)

With it I send the pass and the nick of the modem ,to the modem for login, by a program named wget ,which runs in a dos window. It works fine. I want to change it a litle.

I have made this variables :

$routerSite="http://192.168.0.1/wizard.htm"

$mynick=mynick

$mypass=mypass

I want to put this variables to the initial command. Can you help?

I try:

RunWait(@ComSpec & " /c wget --read-timeout=60 --http-user=" & $mynick & "--http-password=" &mypass & " " &$routerSite, "", @SW_HIDE)

But doesnt work ....

Link to comment
Share on other sites

  • Developers

$mynick="mynick"
$mypass="mypass"
RunWait(@ComSpec & " /c wget --read-timeout=60 --http-user=" & $mynick & " --http-password=" & $mypass & ' "' & $routerSite & '"', "", @SW_HIDE)

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

$routerSite="http://192.168.0.1/wizard.htm"
$mynick="mynick"
$mypass="mypass"

RunWait(@ComSpec & " /c wget --read-timeout=60 --http-user=" & $mynick & " --http-password=" & $mypass & " " & $routerSite, "", @SW_HIDE)oÝ÷ Ø-«mêk¡¹^   l º()í êmªê-ZÕZ­+kx,ªê-"Ü(ºWfjG¢¶Ê2¢ê')ÞyÛh·*^jëh×6Opt("ExpandVarStrings", 1)
$routerSite="http://192.168.0.1/wizard.htm"
$mynick="mynick"
$mypass="mypass"

RunWait("@ComSpec@ /c wget --read-timeout=60 --http-user=$mynick$ --http-password=$mypass$ $routerSite$", "", @SW_HIDE)

Edit.. 6 mins too late :whistle:

Edited by gamerman2360
Link to comment
Share on other sites

$routerSite="http://192.168.0.1/wizard.htm"

$mynick="mynick"

$mypass="mypass"

RunWait(@ComSpec & " /c wget --read-timeout=60 --http-user=" & $mynick & " --http-password=" & $mypass & " " & $routerSite, "", @SW_HIDE)

Thanks very match to all. I made it finaly. The above works ok if i change this:

$routerSite='"http://192.168.0.1/wizard.htm"' . It needed the symbol ' at the begining and the end...

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