0

Is it possible for a vb.net Application Windows Installer (msi) to Run as admin? The problem is that when I start the installer for my application, you have to go through loads and click next( as expected) and then wait for ages and FINALLY you get asked for admin rights to carry on the install..

Is there anyway to run the installer at the beginning as admin so it installs faster or is there any other ways to speed up installation speed?

Thanks

user1244772
  • 294
  • 4
  • 9
  • 22

1 Answers1

1

How big is the MSI? Usually if it takes a lot of time that's an indication that it's big ( hundreds of megabytes ) and windows is choking doing all of it's security checks.

Otherwise, it's functioning as designed. It's not a best practice to elevate the UI sequence. It can be done with a bootstrapper EXE that's manifested to require administrator but it's hard to tell you how to do that since you didn't mention what tool you are using to author the MSI.

Christopher Painter
  • 54,556
  • 6
  • 63
  • 100
  • The installer is only 3mb and once installed about 5mb. Its not a big file just takes the piss installing. – user1244772 Aug 14 '12 at 09:19
  • Also, bin a while since I set up the installer but it was just done through the installer class in visual studio2010. (You can add custom actions and things like that with it too) – user1244772 Aug 14 '12 at 09:22
  • You should know that those project types go away in VS2012 because of the horrible quality. Microsoft suggests migrating to InstallShield Limited Edition (free to VS customers). Windows Installer XML is another alternative. I can't tell you why your MSI is slow without analyizing an installation log. – Christopher Painter Aug 14 '12 at 11:15
  • I have tried using the InstallSheild LE and every time i try and build it I get InstallShield: cannot extract icon with index 0. – user1244772 Aug 14 '12 at 20:24
  • That typically means you created an advertised shortcut for an EXE that doesn't have an embedded icon. Rebuild the EXE with an icon and that message will go away. – Christopher Painter Aug 15 '12 at 02:42
  • It does have an icon. I have tried rebuilding it without an icon and with an icon but the same thing happens – user1244772 Aug 15 '12 at 14:05
  • I have tried linking to the output file as the project to install it and then pointing to a different icon. Same problem. I have tried pointing to the exact exe in the release folder (which has an icon) and same problem. – user1244772 Aug 15 '12 at 14:08