Visual Basic Concepts

The Setup Toolkit

The Setup Toolkit is a project installed with Visual Basic that is used by the Package and Deployment Wizard when it creates a setup program. The Setup Toolkit project contains the forms and code that the application's setup program uses to install files onto the user's computer. When you use the Package and Deployment Wizard, the wizard includes the setup1.exe file that the Setup Toolkit project creates. This file is used as the application's main installation file.

*Note* There are two setup programs involved in the installation process — setup.exe and setup1.exe. The setup.exe program performs pre-installation processing on the user's computer, including installing the setup1.exe program and any other files needed for the main installation program to run. Only setup1.exe is customizable through the Setup Toolkit.

In addition to playing a supporting role in the process of creating a setup program, the Setup Toolkit can be used to modify the screens seen in the installation process, or to create a setup program directly. You might create a custom setup program if you need to add additional functionality not supported by the wizard to your installation sequence.

The Setup Toolkit project resides in the \Wizards\PDWizard\Setup1 subdirectory of the main Visual Basic directory.

*Caution* The files in this project are the same files used by the output of the Package and Deployment Wizard. Do not modify them without making a backup copy in another directory first. If you modify setup1.exe, subsequent setup programs created by the Package and Deployment Wizard will use the modified version.

You use the Setup Toolkit by loading the Setup1.vbp file into Visual Basic and making modifications to the appearance or functionality of the project. In doing so, you may need to manually go through the steps that the Package and Deployment Wizard would otherwise do for you. The following sections describe steps in the process and explain how to determine which files you need to include in your setup, how to create a Setup.lst, how to create distribution media, and how to test your setup.

Overall Steps to Modify the Package and Deployment Wizard

When you modify the Setup Toolkit with the intention of changing the output created by the Package and Deployment Wizard, you follow these steps:

  1. Modify the Setup Toolkit project to contain any new prompts, screens, functions, code, or other information you want to include. When you are finished, compile the project to create setup1.exe.

  2. Run the Package and Deployment Wizard, following the prompts on each screen, to create your distribution media.

Overall Steps to Create a Custom Setup Program

When you create a setup program manually using the Setup Toolkit rather than the Package and Deployment Wizard, you must follow these steps:

  1. If necessary, modify the Setup Toolkit project to contain any new prompts, screens, functions, code, or other information you want to include.

  2. Determine the files you want to distribute, including all run-time, setup, and dependency files.

  3. Determine where to install the files on the users' computers.

  4. Manually create your Setup.lst file to reflect the names and installation locations of all files that must be included for your project.

  5. Determine how you will be distributing files.

  6. Create the .cab files for your project using the Makecab utility.

*Tip* You can use the Package and Deployment Wizard to create your .cab files, then modify the .cab files manually. When the wizard creates your .cab files, it creates a .ddf file and a batch file in the \Support subdirectory of your project directory. To modify the .cab files, edit the .ddf file, then run the batch file provided. The batch file in turn will run Makecab.exe to recreate your .cab files.

  1. Create the setup1.exe for your project by compiling the Setup Toolkit project with your changes.

  2. Copy your files to the distribution media, or manually publish your files to the Web site using the Web Publishing Wizard, available in the ActiveX SDK.

*For More Information* For more information on using the Web Publishing Wizard, see "Internet Tools and Technologies" in the Internet/Intranet/Extranet Services SDK. See "Modifying the Setup Project" later in this chapter for more information on modifying the Setup Toolkit project. See "Files you Need to Distribute" and "Where to Install Files on the User's Machine" for more information on how to place files on the user's computer. See "Creating Distribution Media" for more information on copying your files to the appropriate media.