Last post Jul 21, 2005 10:58 PM by Y2KPRABU
Jul 21, 2005 10:58 PM|Y2KPRABU|LINK
Many of us might have faced this problem while adding a batch file in the webserver.
with some custom actions
I wanted to run custom action code during the Commit phase of the Setup Project.
I created an installer class and override the Commit method. I also added that installer as a custom action to the Commit phase (View->Custom Actions).
During the installation process I got an exception saying
“Could not find C:\Program Files\MyApp\MyAction.Installstate”
The problem is that the MSI infrastructure
is looking for the installation state file which is usually created during the Install phase. If the custom action does not participate in the Install phase, no file is created.
The solution is to add the custom action to both the Install and the Commit phases, although it does nothing during the install phase.