cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Peter_Kosenko
Level 7

Suppress file missing dialog with uncompressed media files?

My company wants to leave our knowledge base files in an uncompressed directory on the CD or media folder so that users can pick and choose which ones they wish to install. The only problem there is that when you remove a file that has been configured into an MSI component, the installer gives you a "file not found" (1308) error. That file not found dialog allows you to continue with the installation, but I know what they really want is to SUPPRESS the dialog in case CERTAIN files are missing. I'm trying to think that one through. Is there a way to capture the the 1308 error, tell WHAT file caused it, and then suppress the error dialog (let the installer go on as if the user pressed IGNORE?). I seriously DOUBT it. It seems like they are asking for something that is beyond the limits of starndard MSI installer behavior and that would require custom programming. (One liability of complete customization is that if you dispense with MSI and just copy files from a folder on the media, you toss away the ability of the installer to check and update files automatically).
Labels (1)
0 Kudos
(4) Replies
Peter_Kosenko
Level 7

I guess what I am looking for is a THIRD option to set in the File table attributes. There are only two options. One is file critical, in which case the installer quits if it is missing. The other is file missing but not critical, in which case a dialog pops that allows you to IGNORE. A third option would be file missing, but intentionally, and NO error dialog appears.

File Table, Attributes column:

Constant Hexadecimal Decimal Description

msidbFileAttributesVital 0x000200 512 The file is vital for the accurate operation of the component to which it belongs. If the installation of a file with the msidbFileAttributesVital attribute fails, the installation stops and is rolled back. In this case, the Installer displays a dialog box without an Ignore button.
If this attribute is not set, and the installation of the file fails, the Installer displays a dialog box with an Ignore button. In this case, the user can choose to ignore the failure to install the file and continue.
0 Kudos
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

Have you tried installing the feature(s) that contain these files as run-from-source? This allows the files to be left at the source location and not be installed locally on a target machine. This option can be set as the default for a feature, or individual components can be set to favor local or favor source as needed to override the containing feature's selection (the default for features and components created in InstallShield is favor local, since this is by far the most likely installation location). The Remote Installation settings for features and components allow changing from the default option.

Note that even with run-from-source, the files contained in any components installed in this manner will still likely need to exist at the source location on the source media (network, CD-ROM, etc.). Also, run-from-source is only available for uncompressed files.
0 Kudos
Peter_Kosenko
Level 7

This is not quite what I am looking for if the files still "have to be in source." What we are looking for is the ability to PULL some of the files OUT of the uncompressed source folder (deliberately) and NOT have the installer complain that they are missing. We want our users to be able to decide which of the "knowlege base" files they want to include in their installations. Our kbases configure default project type estimates based on historical data. Some types of kbases apply to some customers, others to other customers.
0 Kudos
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

The only way this could be accomplished in an MSI setup is by not including the files that are removed from the source media in any components in the MSI. In other words, store the files somewhere and copy them with a custom action (a custom action or RemoveFile entries would also be needed to clean up the files during uninstall). Any files in the MSI File table are going to be subject to this behavior occurring since that is just the way Windows Installer is intended to operate. Even InstallScript, which tends to be a bit more flexible in what can be accomplished in a setup than MSI, would likely have a hard time with this requirement.
0 Kudos