Auto-Incrementing Build Number in Visual Studio and WiX Installer

In AssemblyInfo.cs, remove the “AssemblyFileVersion” attribute, and set “AssemblyVersion” to contain “*” where you want to include the revision and build numbers, like 1.5.*

In the WiX installer’s .wxs file, in the “Product” node, set the “Version” property to look like this:
Version=”!(bind.FileVersion.FileId)“
where FileId is the ID of the file to take the version number from.

Credit to these two StackOverflow posts:
http://stackoverflow.com/a/826850/2939759
http://stackoverflow.com/a/641094/2939759