AutoHotkey Community

It is currently May 27th, 2012, 4:46 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 4 posts ] 
Author Message
PostPosted: March 9th, 2010, 2:46 pm 
I had made a program using ahk on my vista computer, when I copied it over to my windows 7 computer now when i run the program I get the error message...

"Failed attempt to launch program or document"
at the line...
"Run, Audio Process.wrk"

but here is the kicker..it opens the document it is trying to open just fine! but for some reason it thinks that it is not successfully opening it.

Now sometimes it does not produce this error and just works, but it seems to be totally random. I will run my script 10 times in a row and 6 out of the ten times it produces this error. Also, it only happens when I am trying to open this specific kind of file (.wrk files are are work files for cakewalk home studio 2002). I also tested with text documents and it always ran them fine. Is it possible that .wrk files take a little longer to open, so it thinks the file if failing to open when it is really opening just fine??

in the meantime, is there any way I can stop it from producing the false error, it is causing me a lot of problems.. Thanks!


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: March 9th, 2010, 2:57 pm 
Offline

Joined: May 27th, 2007, 9:41 am
Posts: 4999
perhaps try adding %A_ScriptDir%\ and don't post in bugs but in ask for help first, if it is really a bug a mod will move it. Or try setworkingdir

_________________
AHK FAQ
TF : Text files & strings lib, TF Forum


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: March 10th, 2010, 2:49 am 
Offline
User avatar

Joined: October 7th, 2006, 8:45 am
Posts: 3330
Location: Simi Valley, CA
The Manual wrote:
Run, Target, WorkingDir, UseErrorLevel ... If the launch fails, this option skips the warning dialog, sets ErrorLevel to the word ERROR, and allows the current thread to continue.

_________________
Ternary (a ? b : c) guide     TSV Table Manipulation Library
Post code inside [code][/code] tags!


Report this post
Top
 Profile  
Reply with quote  
PostPosted: March 10th, 2010, 3:45 am 
cakepizza wrote:
Is it possible that .wrk files take a little longer to open, so it thinks the file if failing to open when it is really opening just fine??
Yes. I see it all the time with web addresses/html files when Firefox decides to do an update before starting (but does eventually open the address/file).


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

All times are UTC [ DST ]


Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest


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