using a windows form as Custom Action in a Setup Project

Giganews Newsgroups
Subject: using a windows form as Custom Action in a Setup Project
Posted by:  Jassen Cali (JassenCa…@discussions.microsoft.com)
Date: Tue, 1 Apr 2008

I'm really in a bind and I hope there's somebody who can direct me to a clear
answer..

I'm creating an MSI Installer for our system.. before it installs the
program.. It must check :
1. the server exists (for installation on a specific server)
2. if the username and password of the user exists on the server
3. if the database already exists
4. if the connection to the server exists
has 3 buttons :
1. check connection
2. run the script for all the required DBs
3. check if the DB exists
has textboxes for:
1. username
2. password
3. combo box for server list
4. database names
5. path or destination of installation

all these are required by the client.. so I really can't change that.. I
tried using the custom UI windows but none come close to that or it isn't
customizable... so I created a windows form and added it as a custom action
to the MSI Installer.

Everything worked out fine.. until... it just hit me.. what if the user
didn't want to continue the installation? since the windows form is just a
custom action.. when the exit/close buttons are clicked the installation
still continues... How do you cancel or do a rollback do all the transaction
up until that part of the installation? I'm lost.. and I know that I should
probably search for the answer.. I am.. and have been doing so for almost a
week and still continuing to do so.. please could anybody help?

Replies