Build an msi package for Csharp using WiX: Difference between revisions

From munkjensen.net/wiki
mNo edit summary
Line 25: Line 25:
# Click "Tools"
# Click "Tools"
# Select "Wix Setup Editor"
# Select "Wix Setup Editor"
# "Setup project to edit:" should already be filled in as "'''SetupProject''' (..\SetupProject)"
# As "Root directory" select "INSTALLFOLDER (SetupProject)"
# As "Root directory" select "INSTALLFOLDER (SetupProject)"
#  
#  
Line 32: Line 33:
#  
#  
#
#


= References =
= References =


* http://www.mesta-automation.com/create-an-installer-for-c-sharp-with-wix/
* http://www.mesta-automation.com/create-an-installer-for-c-sharp-with-wix/

Revision as of 10:32, 23 November 2016

Preface

This page will describe in short terms how to build an msi package for an Csharp (C#) project. The resulting package will not give the end user any installation options to choose between.


Prerequisites

  • Visual Studio. I used 2015 version.
  • An C# project that does not need the end user to select install options.
  • WiX --> http://wixtoolset.org/releases/ This was written while v3.10.3 was lates stable release.
  • WaX --> In VS 2015 go to "Tools" -> "Extensions and updates", then click "Online" and in the search box type “wax”

Step by step

  1. Install WiX
  2. Install WaX
  3. Open the C# project solution you want to build an msi package for.
  4. Add a WiX setup project to the solution.
  5. Mark your solution in the solution explorer.
  6. Click "File" -> "Add" -> "New Project"
  7. Search for “Windows installer XML”
  8. Select "Setup project"
  9. Type in a name but know that this will be the filename of your msi package. I will use 'SetupProject' from now on and this will result in SetupProject.msi as filename.
  10. Click "Tools"
  11. Select "Wix Setup Editor"
  12. "Setup project to edit:" should already be filled in as "SetupProject (..\SetupProject)"
  13. As "Root directory" select "INSTALLFOLDER (SetupProject)"

References