PDA

View Full Version : problem using iswiautomation in is2011



mary_v
10-29-2010, 04:06 AM
Hi,

used my vbscript since IS2009 but now i am experiencing some problems in Is2011 ...

my script looks like this:

Set oProject = CreateObject("ISWiAuto17.ISWiProject")
oProject.OpenProject "D:\IS2011 Projects\Test\Test.ism"
oProject.ISWiProductConfigs("Product Configuration 1").ISWiReleases("Release 1").Build()
oProject.SaveProject
oProject.CloseProject
Set oProject = Nothing

my script won't compile anymore, the error looks like

...\test.vbs(2, 1) ISWiAuto17: Automation error
> ISWiAutomation.ISWiRelease.BuildInternal
> ISWiAutomation.ISWiRelease.Build


any ideas?

thanks mary

mary_v
10-29-2010, 02:22 PM
... just wondering if the solution for me is too obvious ...?

mary

mary_v
11-02-2010, 10:02 AM
... solved it myself ... (ruined my weekend :mad: )

the same workstation had also IS2010 installed - it now works on a clean machine ... :rolleyes:

mary

Shuttledude
11-12-2010, 02:58 PM
Bummer ... I want to use the same computer for IS2009 and IS2011 projects, at least for awhile. Is there no way to use automation to kick off IS2011 projects unless it is the only installed version of InstallShield??!

Anyone know? :confused:

Shuttledude
11-15-2010, 11:48 AM
This code works for me in Visual Build Pro 7.7 (using it in the Script Editor associated with building an InstallShield 2011 project; works with msi projects and installscript msi projects). It should work with any other build tool or automated script as well.

Use the horizontal scroll bar to see all of the code.



Sub vbld_StepStarted()
Dim pInstaller
' IswiAuto15.ISWiProject is for InstallShield 2009; use IswiAuto17.ISWiProject for InstallShield 2011!
Set pInstaller = CreateObject("IswiAuto17.ISWiProject")
Dim pDatabase

pInstaller.OpenProject Step.ExpProperty(Builder, "Filename")
pInstaller.ProductVersion = Application.ExpandMacrosAndScript("%IS_MY_PRODUCT_VERSION%")

'Change the GUID for the package code
guidString = pInstaller.GenerateGUID()
pInstaller.PackageCode = guidString

pInstaller.SaveProject
pInstaller.CloseProject
End Sub

GarrettDyer
11-16-2010, 10:17 PM
This code works for me in Visual Build Pro 7.7 (using it in the Script Editor associated with building an InstallShield 2011 project; works with msi projects and installscript msi projects). It should work with any other build tool or automated script as well.

Yeah, I have no problem updating the GUID and Properties using the 2011 Automation Interface, but like Mary, the Build method fails for me. I also have multiple versions of IS installed on my build server.

So, I think the question still remains...

oivind-i
06-01-2011, 03:42 AM
I got the same problem (ISWiAuto17).

Can open project, set versions and guids, open ProductConfig and Release. BUT the build operation fails with:

1> Unspecified error
1> > ISWiAutomation.ISWiRelease.BuildInternal
1> > ISWiAutomation.ISWiRelease.Build

I'm also using an old build server with several generations of InstallShield.

It's not always a possible solution to uninstall old versions of InstallShield - they are in use.

This looks like a bug, and if so, Flexera should be able to provide a fix or workaround!

oivind-i
06-01-2011, 03:47 AM
The project builds just fine in the InstallShield application. It's just when building from scripts that it fail.