Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

MSI Error 1720 Installshield X Express


3 replies to this topic

KevinLam215

KevinLam215
  • Members
  • 2 posts

Posted 23 September 2005 - 22:55

Hi, I'm having a problem with MSI Installshield X Express when add in VBScript in Custom Actions to copy a folder by looking for its execution path. The build went smoothly but when I install it, it gives me an error 1720. Below is my vbscript, please help.

Option Explicit

Dim fso, SourceFolder, DestinationFolder, sSourceFolder

Set fso = CreateObject("Scripting.FileSystemObject")

DestinationFolder = "C:\LINKMED\"

SourceFolder = fso.GetAbsolutePathName("Config\")

WScript.echo DestinationFolder

'Call fso.CopyFolder(SourceFolder, DestinationFolder)

Set fso = Nothing

Zweitze

Zweitze
  • Full Members
  • 522 posts

Posted 24 September 2005 - 01:25

I think that fso.GetAbsolutePathName() fails, the param does not look like a valid path.
Further you didn't declare nor initialize the WScript variable. WScript.exe and CScript.exe do have an implicit WScript object, but other Windows Installer does not.

KevinLam215

KevinLam215
  • Members
  • 2 posts

Posted 26 September 2005 - 14:30

This script runs just fine manually. However, when I embeded into my MSI package it doesn't work at all. Any idea how to fix this problem? Thanks a great deal for your help.



Zweitze

Zweitze
  • Full Members
  • 522 posts

Posted 26 September 2005 - 16:04

Get rid of of the WScript object, because that only exists when you run a script using WScript.exe or CScript.exe
When you want to run VB-Script code in different environments, like Excel, IIS, and Windows Installer, the object is unknown and you get a scripting run-time error.