/build/static/layout/Breadcrumb_cap_w.png

Error 1720 - Custom Action

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

Answers (4)

Posted by: rpfenninger 18 years ago
Second Degree Green Belt
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
Posted by: kellerattila 18 years ago
Yellow Belt
0
I inserted the following line:
Set wshell = CreateObject("WScript.Shell")
Sorry to say, the problem has not been solved.
Posted by: timmsie 18 years ago
Fourth Degree Brown Belt
0
why not just use the "moveFile" table instead of a custom action
Posted by: brenthunter2005 18 years ago
Fifth Degree Brown Belt
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...
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ