Cabinets (known as CAB files) are used to package groups of files into a single, compressed archive for distribution. Files in the cabinets must be extracted using a program such as EXTRACT.EXE, that comes with Win95.
Once extracted, these files must be installed using a setup program such as ACME setup. After the files have been installed, they must be manually deleted by the user.
There are three problems with this procedure:
For these reasons a new process, referred to as IExpress, has been created. This process remedies the above problems by providing the following solutions:
These attributes make IExpress an ideal solution for providing programs over the Internet.
There are three components that a package maintainer should be familiar with:
The steps to building a self-extracting/self-installing cabinet are:
The wizard explains things at each step so the basics will not be covered here; however, there are some finer details which require some attention.
You can specify the name of a IExpress Directive File to load on the command line.
Eg. IExpress c:\packages\myfile.cdf
This inserts the filename into the edit box on the first page. It does not open the file, or create the package. If you want to create the package right away without going through the wizard, then specify the "/n" (NOW) argument:
Eg. IExpress c:\packages\myfile.cdf /n
This tells IExpress to build the package right away and return to the command prompt when done. If an error occurs during package creation, then a message box will pop up and wait for you to press the OK button. If the package was created successfully, IExpress will return 0. If an error occurred, IExpress will return 1.
/Q
Tells IExpress not to present any prompts on errors. Useful for automated build processes.Tip: You should use START /W IEXPRESS <app.cdf> /N /Q when doing automated builds of packages.
When you are choosing an installation command, you must make sure it does not run in the background (ie. return to the command line before it has finished processing the files). This is because WExtract will delete all the files that were extracted as soon as the installation program returns, even though the program might still be running.
If you use the Windows 95 "Start" command in your custom install command, then be sure to specify the "/w" parameter so it knows to wait for the process to finish before returning. Eg. "Start /w winword readme.doc"
If using InstallShield you should use SETUP.EXE -SMS when using it inside a IExpress package.
If you choose to install with an INF file, then it must follow the same basic outline as the SAMPLE.INF found in the WExtract tools dir; specifically, it should have a heading "[DefaultInstall]" which lists the steps required to perform an installation.
You should almost always use the "Default" show window attribute. The only time you should use the "Hidden" attribute is to hide a DOS command that starts Windows programs. This can occur if you use the "Start" command or run a DOS batch file that calls Windows programs.