View Full Version : How do I change directories to %AppDir%
In the Actions on the After Install tab page I am running a executable to update some data base files.
Execute(%Appdir%\ins44d63.exe)
I would like it to run from the same directory were it was copied to. But for some reason it think it is running from C:\Windows.
How do I change directories to %AppDir% before I ins44d63.exe is ran?
Darryl
02-19-2002, 03:09 PM
What makes you think that it is running the wrong copy?
The path will be expanded to include the contents of %AppDir% at that moment, therefore I don't really see how the other copy would be executed instead.
------------------
Sincerely,
Darryl Hnatiuk
Indigo Rose Corporation
When ins44d63.exe runs it gets the drive and directory and stores them in local variables. Then it checks to see if a data base file is in the current directory. If it is not then it displays a message with the Drive and directory that it found and stops.
The message that is displayed indicates the directory is the C:\Windows directory and not the %AppDir% that was selected.
Lorne
02-19-2002, 04:11 PM
That sounds a bit odd. Does ins44d63.exe work properly if you double-click on it in explorer?
You could try running the program from a batch file, so you could CD to the desired directory first. (Use text file actions to edit the paths in the .bat file if you need to.)
Tip: to make the batch file window disappear after it's done, end it with
@cls
@exit
Yes it works if I double click it from explore.
So there is know way to change directories?
I realy did not want to use a batch file (dos prompt).
Hi,
Try setting the Working Directory to %AppDir%.
mark.
[This message has been edited by Mark (edited 02-19-2002).]
Ok thank you a lot. I missed that totaly.
[This message has been edited by Jean (edited 02-19-2002).]
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.