PDA

View Full Version : updating the product code GUID from commandline



Markus
02-25-2009, 12:56 AM
Hello,

I'm evaluating Installshield Express at the moment and have the following problem: Our developers are posting builds on a daily basis so after reading in the User Guide I followed instructions on how to Create a Full-Installation Upgrade.
For that I have to change the Product Code each time a new installation is created. Our developers want to create installations via command line - is there a possibility to generate the Product Code via that or what are other options are there that i have missed which allow me to install over previous versions of the software or install the full package if it is not on the target system?

Please consider me as a very new user with very little knowledge in that field...

Thank you
markus

Nick Umanski
06-04-2009, 08:57 AM
I would like to know the same thing, but for the Product Code, Package Codes and Comments field.

I inherited a vbs function which does it for the Version number, but so far been unable to find any help on this which would allow me to update other properties. Here is that vbs code which may be of help to someone:

Option Explicit
Dim svIsm
Dim svVersion
Dim Count
Dim OProject

Count = Wscript.Arguments.Count

If Count <> 2 Then
MsgBox "Project and Version number must be supplied at command line"&Chr(13)&Chr(13)&"Args = "&Count,0,"Incorrect Parameters"
Wscript.Quit
Else
svISM = Wscript.Arguments.Item(0)
svVersion = Wscript.Arguments.Item(1)
Wscript.Echo "Updating "+svISM+" to version: "+svVersion
Call UpdateVersion( svISM, svVersion )

End If



'============================
'SUB UpdateVersion
'PURPOSE Updates project version and saves
'=============================

Sub UpdateVersion( svISM, svVersion )

Set OProject = CreateObject( "IsWiAuto14.ISWiProject" )
OProject.OpenProject svISM
OProject.ProductVersion = svVersion
OProject.SaveProject
OProject.CloseProject
Set OProject = Nothing


End Sub

_______________________________

It is called from within a .bat file like this:

Cscript AutoUpdateVersion.vbs "MyProject.ism" 3.50.0000

I should add that IsWiAuto14.ISWiProject is for an InstallShield 2008 project and I use it to update Basic MSI projects.