Hi All,

I used a Custom Action ( stored directly ). After installing the MSI package I got an 1720 Error ( A script required
for this install to complete could not be run. Contact your support
personnel or package vendor).

Here is the code:

Option Explicit

Dim objFSO, objFileCopy
Dim strFilePath, strDestination

strFilePath = "C:\Progra~1\UltraE~1\UltraE~1.exe"
strDestination ="C:\Progra~1\UltraE~1\UEDIT32.exe"


Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objGuyFile = objFSO.CreateTextFile(strFilePath, True)


Set objFileCopy = objFSO.GetFile(strFilePath)
objFileCopy.Move (strDestination)
Wscript.Quit

Someone has any idea ?

Thanks in advice
KA
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
Don't forget to mention the following when executing a vbscript within an msi:

Set wshell = CreateObject("WScript.Shell")

The explanation of why is here (last note)

Or otherwise use message boxes to find out where exactly the script is failing.

Cheers
Answered 02/15/2006 by: rpfenninger
Second Degree Green Belt

Please log in to comment
0
I inserted the following line:
Set wshell = CreateObject("WScript.Shell")
Sorry to say, the problem has not been solved.
Answered 02/16/2006 by: kellerattila
Yellow Belt

Please log in to comment
0
why not just use the "moveFile" table instead of a custom action
Answered 02/16/2006 by: timmsie
Fourth Degree Brown Belt

Please log in to comment
0
You're code seems fine, but you can't use the following line in VBScript custom actions:
Wscript.Quit

I would also suggest using the MoveFile table, unless of course you need this file moved at the very end of the installation sequence etc...
Answered 02/16/2006 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
Answer this question or Comment on this question for clarity