PDA

View Full Version : InstallScript CA in MST?



soorajganga
02-28-2007, 08:12 AM
Hello experts!

Is this possible to have a InstallScript custom action in a windows transform (.MST) ?

If YES, how do we do that using Adminstudio?

If NOT, Why is that not possible/allowed?

Replies are highly appreciated...

Thanks

Christopher Painter
02-28-2007, 10:26 AM
InstallShield does not support this, but it's possible starting with InstallShield 12.

Basically an InstallScript CA is compiled into a DLL and given a function export like `f1` or `f2` as a target.

Build a fake MSI project to contain your InstallScript CA. Then use InstallShield Direct Edit or ORCA you can look at the CustomAction table to see what the binary key name is and the function target is. Then export that Binary table record out to a fille like MyCA.dll.

Then when you author your transform, import the DLL into the binary table ( changing the key column to avoid naming conflict with other InstallScript CA DLL's ) and then author the CustomAction table to point to the new row in the binary table. Finally, wire the CA into the approriate sequence of ControlEvent with the approriate conditional expression to do what you need.

Make sense?

soorajganga
03-01-2007, 06:56 AM
Make sense??....Hmmmm...not really :)

First of all, I need to do this with AdminStudio 8! and second, I am not able import a dll to table. (How do I do this?). I guess if I can import an external dll to a table, I may be able to follow your steps to make it happen!!!

Above all, why doesn't it supported in InstallShield?

Thank you so much for the reply...

Christopher Painter
03-01-2007, 10:11 AM
You create your transform, go to direct edit more, select the Binary table and click at the bottem to create a new row. Give the row a KeyName and click in the Data column and you'll get a popul asking you to import a file. The file path will be shown and when you build the transform it'll be in there.

I can't answer why the ability to author InstallScript CA's in a transform or merge module doesn't exist. I don't work for Macrovision. I just know how the technology works and how to make it happen indirectly.