1

I am creating an MSI package for a windows service, untill recently i have always just performed the minimum using the installer class and then manually edited the app.config file afterwards. However, i need to make it easier for the users to carry out an installation themselves and this has meant replacing manual configuration with prompts at install.

I have managed to add a custom action to display a textbox and prompt for a folder destination, as well as ammending the installer to create the folder using the filepath entered into the text box, but i would prefer it if the filepath could be selected by browsing to the folder.

Can anyone suggest a good tutorial or steps to do this, as i am struggling.

Thank you

Adam Pope
  • 3,234
  • 23
  • 32
  • How do you create your msi package? Is your custom action showing a dialog? Did you try using OpenFileDialog http://msdn.microsoft.com/en-us/library/system.windows.forms.openfiledialog.aspx? – rene Mar 02 '11 at 11:13
  • Are we to assume it's a *shudder* Visual Studio Setup Project? Please add a tag for that (or for Wix, InstallShield, whatever system you are using) – Damien_The_Unbeliever Mar 02 '11 at 11:27
  • @Damien_The_Unbeliever .... afraid so... Do i need a new question for 'how do i add tags to exisitng questions?' – NottinghamDrew Mar 02 '11 at 11:28

1 Answers1

0

This would mean a redo, but you could use WiX to build your installer.

It has built in support for everything you need, and I don't think you would need any custom actions at all (unless there is something special you don't mention).

It does have a bit of a learning curve, however. Even if you don't go with it this time, it would be worth looking into for a new project.

jonathanpeppers
  • 26,115
  • 21
  • 99
  • 182
  • Thank you, i will have a look at this. In all honesty the overhead for too many changes vs costs is probably going to mean just telling them to copy and paste the file path from the distination folder. – NottinghamDrew Mar 03 '11 at 10:38