Here is the vbscript that runs at the very first and generates the GUID and property which I call "iid" for installer id:
Code: Select all
Function GenerateGuid()
Set TypeLib = CreateObject("Scriptlet.TypeLib")
Dim sGuid
sGuid = TypeLib.Guid
sGuid = Replace(sGuid, "{", " ")
sGuid = Replace(sGuid, "}", " ")
sGuid = Trim(sGuid)
Session.Property("iid") = sGuid
End Function
installid [iid]
Where "installid" is the command line parameter for my exe and "[iid]" is the property I generated earlier in the install.
What's strange is that referencing [iid] and passing it as a post parameter works great. But on the last part of the install, when I pass it to my exe, I get an empty string for the value. So for some reason, it looks like either I am referencing it wrong in the command line parameters for the custom action or am I uncovering a bug?
FOLLOW US
Get the latest news in Application Packaging