cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
AlexK69
Level 3

exclude some files or components from compression

My problem is that I need an .msi file with all but two files from the installation.
Our software is not for the mass market but for big customers. These two files we need separate from the rest of the setup are customer specific and are tailored for each customer by our support people.

We've used WfWI some time ago and there was a possibility on a per component basis. Now in Installshield I've searched for such a feature, but it seems to be an all or nothing thing here.
Even in the premier edition...

What I need is what Visual Studio 2010 does when the file property "PackageAs" is set to "vsdpaLoose".
Labels (1)
0 Kudos
(6) Replies
skolte
Level 7

Would it help if you add those files as support files? Try adding them under Behavior and Logic > Support Files/BillBoards > Language Independent...right click in Files area and select Insert Files.

We use this approach as we have a SQL Installer that we simply need to be copied over to target directory if required.
0 Kudos
AlexK69
Level 3

Thanks a lot!
That was exactly what I needed!

Just one thing:
skolte wrote:
Behavior and Logic > Support Files/BillBoards > Language Independent

there's a mistake.
The correct "path" is "Behavior and Logic > Support Files > Splash Screen > Language Independent"

But, to be honest, it's far from a clean solution...
Flexera should definitely add an option for that. I'm obviously not the only one with this problem...

EDIT: I've found an even cleaner solution!
"Behavior and Logic > Support Files > Advanced Files > Disc 1"
There you can even choose on what disk the file should be stored (in case of a multi disc installation).
0 Kudos
AlexK69
Level 3

Ok, now there's another problem...

The file is now on the installation disc, but how do I get the installer to copy it to the destination directory?
In other words, how do I link it into a component or feature?
0 Kudos
skolte
Level 7

Are you using InstallScript or InstallScript MSI?

If you are, that would be easy. I would go to InstallScript tab, and add OnEnd event. One way to do it is once you are in InstallScript view, you will see two dropdown boxes at the top of the screen. In the first dropdown select After Move Data and in second dropdown select 'OnEnd'.

InstallScript will add OnEnd() code automatically. Add a line there to copy your file from your INSTALLDIR to any location you want.
e.g If you want to copy a support file named 'abc.txt' to a 'Logs' directory you would do something like:

function OnEnd()
begin
CopyFile(INSTALLDIR^"abc.txt", INSTALLDIR^"Logs\\abc.txt");
end;


Btw, for any reason if you have to access the SUPPORT files during the install process and you can directly refer to them using [SUPPORTDIR] in your installscript.
0 Kudos
AlexK69
Level 3

Thanks a lot, I'll give it a shot on Monday 🙂

FYI: I'm using MSI. I also have to make sure that the file(s) get deleted on uninstall.
0 Kudos
skolte
Level 7

If you want to delete those on UnInstall, just override OnUnInstall() and put code there to delete the files. Or better yet, add the files to the RemoveFile table, this should remove the files even if they were Read Only. I think you will have to associate them with some component. Look up 'RemoveFile table' in documentation.
0 Kudos