Or choose the
Orca Tool to validate for license information like a serial number. There is a Microsoft Support article
here, that talks about the steps involved in using Orca to customize windows installer that validates a serial number.
Also, there is an
article on Code Project that throws more light on the same concept that is briefed in the Support article link above. And also provides you downloadable source code.
I would even look at an alternative solution to Visual Studio: Wiks to be able to deliver a wholly customizable windows installers, which are pretty highly configurable and reliable.
Hope it helps.