PDA

View Full Version : Sub-Directories not installed in [INSTALLDIR]



JPScerri
01-02-2003, 09:00 AM
I created a folder containing some files an Sub-Directories containing other files. Then I create an IS Project and linked the files to the directory, set the INSTALLDIR to [ProgramFilesFolder]My Apps\App 1

I then created 2 Custom Actions.

The first is invoked After Initalization. I simply searches a specific path in the registry containing the last path where the application was installed. If found, it replaces the INSTALLDIR property to that value, else, it leaves it unchanged.

The second is invoked After Setup Complete Success dialog. It simply writes to the registry the INSTALLDIR property.

I then compiled the setup and launched it. I only changed the Destination Folder to C:\Program Files\My Apps\App 2. Installation will be fine and ALL files are installed in C:\Program Files\My Apps\App 2.

Then I deleted a Sub-Folder from C:\Program Files\My Apps\App 2, Changed the product version & Product Code and re-compiled.

When I run the new setup, it automatically displays the destination dir as C:\Program Files\My Apps\App 2, but when it finishes installing, the directory that I deleted, will be installed in C:\Program Files\My Apps\App 1. Moreover, files in the root directory are installed correctly !!

Can anyone HELP Please ????

Mike Marino
01-02-2003, 12:14 PM
It sounds as if the MSI Directory table in your project might have some bad data in it. Is it possible for you to email me your .ISE file?

If so, email it to

michaelm@installshield.com

Chandima
01-06-2003, 04:52 PM
Are you using a VBScript to reset the value of INSTALLDIR? If so are you using the following:

Session.Property("INSTALLDIR")="C:\Test\Express"

If so this is the cause of the problem. To fix use the following line of code instead:

Session.TargetPath("INSTALLDIR")="C:\Test\Express"

Let me know if this works or not.