I want to preserve some files when a user moves up to a new version, so I'm using an Install CA to copy the files to a tmp directory and a Commit CA to copy them back. (If there's a better way, please let me know!)
My VBScript works fine outside the installer but fails in it. Here's the problem code with the JRE key used for testing:
Code: Select all
Dim oShell
On Error Resume Next
Set oShell = WScript.CreateObject("WScript.Shell")
If Err.number <> 0 Then
MsgBox "Error in shell", 16, "error"
MsgBox Err.number, 16, "error"
Err.Clear
End If
FYI, I also tried using CRegistry as per Peter Furnett's post but that didn't work for me even outside the installer (didn't get the value).
Can anyone help me out of VB hell?
Thanks.
gs
FOLLOW US