AutoHotkey Community

It is currently May 26th, 2012, 10:46 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 2 posts ] 
Author Message
PostPosted: June 30th, 2009, 2:44 am 
Offline

Joined: January 20th, 2007, 1:29 pm
Posts: 96
Location: Melbourne
i have been going nutz over losing my variable data when using c1 c2 c3 etc when using UrlDownloadToFile, whenever UrlDownloadToFile was called, any variable called c1 c2 c3 c4 etc was wiped, i finally did the following test and comfirmed the bug
Code:
 
msgbox % c1  " - " c2 " - " c3 " - " c4 " - " c5
UrlDownloadToFile,%myserver%/%c1%,%A_ScriptDir%\%c5%.d
msgbox % c1  " - " c2 " - " c3 " - " c4 " - " c5

the first msgbox showed all my variables perfectly
it then downloaded what was asked for
then the second msgbox just showed - - - -
yet the file i asked for, was present and Correct.

all the c variables get deleted whenever UrlDownloadToFile was used
i changed the variable to d and it then worked fine.

_________________
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: September 17th, 2009, 6:49 pm 
Offline

Joined: March 2nd, 2004, 3:36 pm
Posts: 10720
I can't reproduce it using the following script:
Code:
myserver = http://www.autohotkey.com
c1 = index.htm
c2 = c2
c3 = c3
c4 = c4
c5 = c5

msgbox % c1  " - " c2 " - " c3 " - " c4 " - " c5
UrlDownloadToFile,%myserver%/%c1%,%A_ScriptDir%\%c5%.d
msgbox % c1  " - " c2 " - " c3 " - " c4 " - " c5

Perhaps there is a timer or something else in your script that also uses those variables and is interfering. Also, if your version of AutoHotkey is very old, you could try the latest one: www.autohotkey.com/download/


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Google [Bot] and 3 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group