PDA

View Full Version : different directory for each feature



workaholic
04-10-2006, 02:19 PM
I've tried to search the forum, but I keep getting a blank page when it finishes loading.. so if this is a duplicate, I apologise.

I have 3 features in my Installshield MSI project. I need each one to default to the user's system directory to be installed in, but be able to let the user separate each component to install in different locations.

The program dlls are sometimes installed with the application's EXE program.

How would I go about this?

Thanks,

Earl

Buddy Jain
04-13-2006, 12:55 AM
Associate file / directory with with different feature in file view.. then set different directory for feature..

Hope this helps...

workaholic
04-13-2006, 08:54 AM
Thanks for the reply.

I do know how to associate the feature with another directory, but how do I default that directory to the users 'system folder'? :confused:

Thanks,

Earl

Buddy Jain
04-17-2006, 10:36 PM
Set INSTALLDIR property to systemfolder.

workaholic
04-18-2006, 09:28 AM
Right - that works, but I think I need to explain myself further.

I have 3 features, that I want to default to be installed to the SystemFolder.

BUT - I need the user to be able to change one of these to be a different folder.

If I set all three features destinations to default to the INSTALLDIR, and the user changes one of them when the installation program is running, all three features are changed to this new path.

I need to be able change one, without changing the other features.

How do I create another 'destination' that defaults to the SystemFolder, but has a different name, so that I don't change all three features destinations when I change the path for one?

Thanks,

Earl

Buddy Jain
04-19-2006, 12:11 AM
Hi,

Have you created subfeatures of a feature... If you change a feature setting it will effect subfeatures as well..

In this case, possibly user is changing parent feature location and that is causing location change of subfeature as well.. don't create subfeature, if you want to achieve this.

So in order to accomplish this, create stand-alone features, which can run indepdent of each other. Make 3 features siblings of each other thus user can change the location of one feature without affecting the location of other feature.

Hope this will help.

workaholic
04-19-2006, 03:28 PM
I checked, and I don't have sub features.

I have three separate features on the first level.

All three have a destination of [INSTALLDIR]

When running the installshield setup.exe program, when I get to Custom Setup, and I change one of the features to a different directory, all three are changed to that directory.

Thanks,

Earl.

Buddy Jain
04-20-2006, 01:54 AM
Hi,

I checked this at my end, and everything seems to work fine.

I have gone through the following steps, see if you get some help from this :

I created 3 seaparte feature named Complete, A and B. I have put one text file in each feature named Complete.txt, A.txt and B.txt respectively.

By default all goes to Systemfolder i.e. I have set directory for each feature as "C:\windows\system32"

Even though I change the directory for any one of the feature during installation, it doesn't affect location for other feature.

You can test by running the attached test.MSI file.

workaholic
04-20-2006, 09:55 AM
That's why I'm having the problem.

I can't hard code the directory to c:\windows\system32

I was using the [INSTALLDIR] directory entry, and defaulting the [INSTALLDIR] to the SystemFolder.

So - my question needs further adjustment...

I need to default the features to install to the users SystemFolder.

I can't choose SystemFolder as a destination, so I need to be able to create a variable/string or something that can default to the System Folder, so I can use it in the Destination for the Feature.

Is this possible?

Thanks,

Earl

TsungH
04-21-2006, 12:32 AM
In short, yes. When one directory property is used for all 3 features, all 3 features will go to where the directory property points to. You need to create a separate entry in Directory table and set that to have the same value as SystemFolder property. The newly created directory property can then be used for feature's and component's destination.