I have an application installed on my machine. I also have its source code but somehow the ProductCode and UpgradeCode of this application were changed.
If you don't have the msi and you need the upgrade code, rather than the product code then the answer is here: How can I find the upgrade code for an installed application in C#?