*****Building a DEBUG CVI Distribution Kit***** OVERVIEW CVI's Distribution Kit functionality utilizes a third-party product called Instalit from HPI. You may debug problems encountered while running the Distribution Kit installer in a straightforward manner. A completed kit contains an executable named SETUP.EXE. This executable is actually the combination of a standard, default SETUP.EXE, and a script file specific to your application and project settings. To debug the installation, you must isolate this script file from the SETUP.EXE executable. The following paragraphs outline the appropriate procedure, assuming you have already created the problematic Distribution Kit and placed it in a directory on your machine (referred to as the "kit directory"). STEP 1 - Specify a floppy drive as your "Target Path" Select "Create Distribution Kit" from the Build menu just as you did to create the problematic Kit. In the "Target Path" text box, specify your floppy drive (A:). All other options should remain as they were when you built the kit initially. Do not go any further. STEP 2 - Obtain temporary script file CVI uses the directory pointed to by your TEMP environment variable (usually C:\Temp) to store the temporary script file it creates. You must obtain this file. From the Create Distribution Kit dialog, select "Build." Several progress dialogs run to completion as CVI compresses the appropriate files and generates the script. A "LabWindows/CVI Message" dialog then appears asking you to insert a floppy disk. Before doing anything with this dialog, check the TEMP directory for a file that has a name similar to your project's name with a .INF extension. This is the temporary script file that you need to debug the SETUP.EXE application. Copy the file to another directory and then "Cancel" out of the dialog. Another message dialog will appear, just select "OK." STEP 3 - Replace SETUP.EXE file Now that you have obtained the temporary script file, delete the SETUP.EXE you created earlier from your Kit directory (with the SETUP.EXE and .XXX data files). Copy the SETUP.EXE from the CVI\BIN directory into the kit directory, as well as the temporary .INF script file. STEP 4 - Add breakpoint debugging commands Open the .INF script file with a text editor. It is in a standard script format, made up of a Main and other sub procedures. The following line: SetTraceMode On will serve as a "breakpoint" in the script. Insert this line wherever you want to break the script execution. You can step through the script line by line once execution has been suspended, and you can place as many breakpoints as you like. STEP 5 - Debug the Distribution Kit installation Run the SETUP.EXE you copied from your CVI\BIN into your kit directory. This is the normal setup application, and it will run through the .INF script to which you added breakpoints. When the script reaches the breakpoint, you will see a "debugging" dialog that allows you to step through execution. Note that the line number indicated in any installation error dialog directly corresponds to a line in the .INF script file, which is not the case with the normal, combined script. Using the debug functionality, you can determine the exact operation that fails during the installation and make necessary permission or other adjustments.