0

Using DTF i can get the installed product fine using the following code.

        var product = (from p in ProductInstallation.AllProducts
                       where p.Publisher == CompanyName && p.ProductName == ProductName
                       select p).FirstOrDefault();

But the properties i want to update don't have a setter. Like the Version. Everything else in DTF seems to be against an MSI not an installed product

Ryan Burnham
  • 2,619
  • 3
  • 27
  • 43

1 Answers1

2

It doesn't have a setter because that wouldn't make sense If I have FOO.MSI 1.0 and install it, it gets registered with MSI. Why would should I then be able to tell MSI that it's really 1.1? I'd have to get FOO.MSI 1.1 and performa an upgrade in order to be able to do that.

Christopher Painter
  • 54,556
  • 6
  • 63
  • 100
  • The problem is the files are patched with a separate service but the windows installer detects the change and runs a repair. I need a way to tell it what its been updated to – Ryan Burnham Apr 18 '12 at 23:48
  • While you should only service (patch) and MSI with an MSP, I happen to know from (renegade) experience that as long as you version the EXE/DLL files higher MSI won't trigger a repair (resilency) and if you manually invoke a repair your higher version will remain. If you do however delete the DLL and do a repair you'll get the old version back. – Christopher Painter Apr 19 '12 at 00:33
  • right, what would happen if you replaced it with the same version? would it do a repair? BTW the original install is done using InstallShield. – Ryan Burnham Apr 19 '12 at 00:35
  • Provided InstallShield wasn't set to "always overwrite" it would be preserved. – Christopher Painter Apr 19 '12 at 01:03