fender4645
04-08-2004, 04:05 PM
Hi all-
I'm using the Kinook-recommended script to increment build numbers:
----
Set objMacro = Application.Macros(vbldProject).Item("BUILD_NUM")
If objMacro Is Nothing Then
' if the macro doesn't exist yet, initialize to 100
Application.Macros(vbldProject).Add "BUILD_NUM", "100"
Else
' otherwise increment the value
objMacro.Value = CLng(objMacro.Value)+1
End If
-----
I'm also using the recommended script to incrememnt the version of my IS 9 installer:
-----
Set objInst = CreateObject("ISWiAutomation9.ISWiProject") ' use "ISWiAutomation9.ISWiProject" for DevStudio
' open the project file
objInst.OpenProject "E:\installers\app\App.ism"
' retrieve and split the ProductVersion
verArr = Split(objInst.ProductVersion, ".")
' increment last field
verArr(UBound(verArr)) = CStr(verArr(UBound(verArr)) + 1)
' update the project
objInst.ProductVersion = Join(verArr, ".")
' and save changes
objInst.SaveProject
objInst.CloseProject
-------
Is there any way to carry over the 'BUILD_NUM' macro from the first script and use it in the IS script? I pretty much have no VB experience and I'm not sure exactly haw the IS script is really working.
Any help would greatly appreciated. Thanks!
I'm using the Kinook-recommended script to increment build numbers:
----
Set objMacro = Application.Macros(vbldProject).Item("BUILD_NUM")
If objMacro Is Nothing Then
' if the macro doesn't exist yet, initialize to 100
Application.Macros(vbldProject).Add "BUILD_NUM", "100"
Else
' otherwise increment the value
objMacro.Value = CLng(objMacro.Value)+1
End If
-----
I'm also using the recommended script to incrememnt the version of my IS 9 installer:
-----
Set objInst = CreateObject("ISWiAutomation9.ISWiProject") ' use "ISWiAutomation9.ISWiProject" for DevStudio
' open the project file
objInst.OpenProject "E:\installers\app\App.ism"
' retrieve and split the ProductVersion
verArr = Split(objInst.ProductVersion, ".")
' increment last field
verArr(UBound(verArr)) = CStr(verArr(UBound(verArr)) + 1)
' update the project
objInst.ProductVersion = Join(verArr, ".")
' and save changes
objInst.SaveProject
objInst.CloseProject
-------
Is there any way to carry over the 'BUILD_NUM' macro from the first script and use it in the IS script? I pretty much have no VB experience and I'm not sure exactly haw the IS script is really working.
Any help would greatly appreciated. Thanks!