Microsoft provide software developers a component called Microsoft Installer, or MSI to friends, wich contains all the functionalities needed to install, mantain or remove the application from a Windows System.
To start open the context menu of your solution node in the solution explorer dock: Add\New Project. Then you will see the figure shown below:
So this is the basics about MSI, but what i want to write about is Custom Actions and what i learned about it today. So i needed to transfer information between two different custom actions and i thought that i could use the parameter stateSaver from the event install, but it did not workout because it is used to save installation parameters to be shared across all the installation events of the custom action in context. So i questioned my colleague Abel about a idea to solve the problem, and the answer could'nt be more simple, "try to use a static dictionary". With that in mind i created a static class with a property that is a Dictionary and other information, refactored the code to use my new class and went for testing. Result, the test worked out in the first try.
References:
http://en.wikipedia.org/wiki/Windows_Installer
http://devcity.net/Articles/339/3/article.aspx
http://msdn.microsoft.com/en-us/library/aa368066(VS.85).aspx
No comments:
Post a Comment