How To Run Setup1.vbp in the Design Environment

Last reviewed: November 26, 1996
Article ID: Q159860
The information in this article applies to:
  • Standard, Professional, and Enterprise Editions of Microsoft Visual Basic, 16-bit and 32-bit, for Windows, version 4.0

SUMMARY

You can customize the installation program created by the Setup Wizard by modifying the Setup1.vbp project in the \Vb\Setupkit\Setup1 directory. However, you cannot run or debug this project in the Visual Basic Design Environment unless you emulate the behavior of the compiled setup routine.

NOTE: Microsoft Technical Support does not support the modification of the setup process or any of the setup files. Support is provided for the Setup Wizard on an "as is" basis only.

MORE INFORMATION

Before you can run Setup132.exe, the Setup.exe program must copy certain files to their destination directories (all files listed in the "[Bootstrap]" section of the Setup.lst file). Setup.exe also creates an uninstall log file that is used by Setup1.exe for 32-bit applications. It also copies Setup1.lst to your \Windows directory so that it will not be swapped out.

Setup.exe invokes Setup1.exe with certain command line parameters. In order to run the Setup1 project in the Visual Basic Design Environment, these parameters must be set. Do this by launching the Visual Basic Design Environment from the Setup program and specifying your modified Setup1.vbp as a command line parameter.

NOTE: The file Setup1.exe is created for a 16-bit application and Setup132.exe is created for a 32-bit application. The following example focuses on 32-bit applications, but can be readily adapted to 16-bit applications.

Step-by-Step Example

  1. Run the Application Setup Wizard and follow the steps to produce the default setup distribution set in a directory.

  2. Edit the file Setup.lst in a pure text editor, such as Notepad. Locate the following entry:

    Setup=setup132.exe

    and replace it with:

    Setup=c:\vb\vb32.exe c:\vb\setupkit\setup1\setup1.vbp /cmd

    Modify the path as appropriate. Save Setup.lst when this step is complete.

  3. Run Setup.exe from the installation directory. Instead of running Setup132.exe, Setup.exe starts up the Visual Basic Design Environment with the Setup1.vbp project loaded, the correct files in the correct places, the uninstall log already created, and with the command-line parameters set properly. This is the function of the '/cmd' parameter. It allows Visual Basic 4.0 to pick up the command-line parameters that Setup.exe sends to Setup132.exe. Refer to the Advanced tab option of the Tools/Options menu to confirm what parameters were passed.

  4. Add the desired break points. Press the F5 or F8 key to run the project.

    Note that if you click the "Exit Setup" button at any time while running the project, or if the program runs to the end either successfully or by a trapped error, the log file (setup.lst) and the uninstall program are deleted. Conversely, if you run repeated tests of your version of Setup132, then multiple copies of the log file (St4unst.000, St4unst.001...) are copied into your \Windows directory. These may be safely deleted after you exit the Visual Basic Design Environment.


KBCategory: kbsetup kbtool kbhowto
KBSubcategory: TlsSetWiz
Additional reference words: 4.00 vb4win vb4all kbstream


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: November 26, 1996
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.