PDA

View Full Version : One level upper than %CURDIR%



MichalCh
12-07-2007, 05:46 AM
In our product we always 'wrote' update.exe in path 'application Folder\update' . I would like my update aplication, after launch, provide installing files into main aplication dir so into directory one level upper than %curdir%.

Is there any way how to write the path in my case?
Thanks in advance

Michał

linder
12-07-2007, 06:17 AM
Michał,

Sorry, I fear I do not understand. What is update.exe? Is this a customized wupdate.exe web update client?

Let us assume, the user installed update.exe into c:\program files\your cool app\update.

You would like to install update files into c:\program files\your cool app, right?

Friedrich

MichalCh
12-10-2007, 04:27 AM
Yes, U R right.
We develop such algorithm of update : when newer update.exe file on the serwer appear, our_aplication (when launched on end user PC) starts to download update.exe and put in into /update dir.

Next after restart (of my app.) the update.exe ( so my SB project) starts and overwrite some files.

I found solution of the problem named in the title as follow: [INSTALLDIR]: %CURDIR%\..\ - it works when I copy my update.exe file into /update directory and launch it 'manually' by dobleclick - files were copied into dir one_level_higer.

I was little confused when mensioned algorithm (instaling update by restart of my ap.) did't work fine with aboved SB config.

Finaly I realized that in my case %curdir% is the one where main executable file is placed (and launched) - not /update dir where update.exe is written , so only %CURDIR% as [INSTRALDIR] is enough for finding right path for my use.

I am sorry for the case ,and your time, hope maybe it could be helpfull for someone in the future.

Kind regards,
Michał

linder
12-10-2007, 04:36 AM
Michal,

It's always a good idea to use the "Get System Information -> Installer Path Name" script function to determine the full pathname, excluding the file name, of the installation application currently executing.

Friedrich