Paul Michaels
Paul Michaels

Reputation: 16695

Debugging VS2008 VBScript custom install task

I have an install project which has a custom action that executes a VBScript file. As it stands, this installation fails during the execution of this script with the following error:

There is a problem with this Windows Installer package.  A script required for this install to complete could not be run.  Contact your support personnel or package vender.

The script looks fine to me, but I can't see a way to debug it. Is there a way to output a trace message, or even pause execution of an install script for this purpose?

Upvotes: 2

Views: 766

Answers (1)

user128300
user128300

Reputation:

You could try to insert the following lines into your script to output debug messages to a log file:

Set objFso = CreateObject("Scripting.FileSystemObject")
Set f = objFso.OpenTextFile("C:\Temp\logfile.txt", 8, True)
f.WriteLine "Debug message text"
f.Close

Upvotes: 1

Related Questions