Page 1 of 1

Calling .NET Installer Class

Posted: Mon Nov 20, 2006 5:31 pm
by tltaylor76
I have been creating a lot of .NET installer classes to get around certain shortcomings of MSI. But the limitation that I have found is that you can only have one Installer class per assembly. Is this correct or am I missing something? It would be nice to have as many different Installer classes within a .NET assembly then specify which one to use when called. Thanks.

Posted: Tue Nov 21, 2006 6:43 am
by MichaelNesmith
With InstallAware, the recommended approach is to use MSIcode to add increased levels of reliability and predictability to your setup. .NET Installer Classes are not recommended - even by Microsoft - as they carry the same ills that self-registering DLLs do.

Posted: Tue Nov 21, 2006 10:16 am
by tltaylor76
Well, I would have to respectfully disagree with you on this item. Considering you cannot even create a loop without GoTo commands (which cannot be within an IF statement) I have found many limitations to the MSI code. It is very difficult to parse arrays, comma delimitted strings, etc. So as far as I can tell, I am limited to something outside of the MSI script environment to do anything that is relatively complicated.

Posted: Tue Nov 21, 2006 5:59 pm
by MichaelNesmith
If you have to do complex processing for items that are not covered in MSIcode, just call a DLL using Call DLL Function, or build a full-blown IDE plug-in in your favorite programming language. Plug-ins especially become a native part of your MSIcode script and are very versatile.

We build the entire update script in MSIcode. That is a testament to the power of the language (and it does many things you mention in your post, such as looping, parsing, and so on). Of course, we realize that you are most comfortable in your native IDE. So, just build a plug-in and add it natively to the MSIcode script.