sosimple Posted November 5, 2007 Share Posted November 5, 2007 (edited) Hi it is a bit complicated .. I have this CODERunWait(@ComSpec & ' /c wget -P c:\temp --referer=http://www.*****.com http://****.com/myfile.rar', "", @SW_HIDE) I have used *** for not showing the site I am interested in . Its not important. What I want to do is use a variable to the above script for the adress of the hard disc I want to save the file i download from the above site. The wget.exe is a program I call from the script to download the file. So , I need to do CODE$directory="c:\temp" RunWait(@ComSpec & ' /c wget -P $directory --referer=http://www.*****.com http://****.com/myfile.rar', "", @SW_HIDE) The above of course is not working. Is it possible to do this? Thanks , Edited November 5, 2007 by sosimple Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted November 5, 2007 Moderators Share Posted November 5, 2007 Just curioius... InetGet doesn't work for you? 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...
sosimple Posted November 5, 2007 Author Share Posted November 5, 2007 no because the site uses a redirection protection, which i solve with wget .... Link to comment Share on other sites More sharing options...
DirtDBaK Posted November 5, 2007 Share Posted November 5, 2007 $directory="c:\temp" RunWait(@ComSpec & ' /c wget -P' & $directory&' --referer=http://www.*****.com http://****.com/myfile.rar', "", @SW_HIDE) [center][/center] Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted November 5, 2007 Moderators Share Posted November 5, 2007 no because the site uses a redirection protection, which i solve with wget ....Try this:$sDir = @HomeDrive & "\temp" $sURLIn = "http://www.*****.com" $sURLRedirect = "http://****.com/myfile.rar" RunWait(@ComSpec & " /c wget -p " & $sDir & " --referer=" & $sURLIn & " " & $sURLRedirect, "", @SW_HIDE) 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...
sosimple Posted November 5, 2007 Author Share Posted November 5, 2007 Thank you all very very much. I tried the script of Dbak and works excellent . The script of smoke N gives me new ideas, and i am sure does the same more "systematic" . I'll tried it next. Thanks again all i couldnt do this by myself 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