Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. about setup projects

about setup projects

Scheduled Pinned Locked Moved C#
windows-admincsharpc++databasevisual-studio
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Mauricio Ritter
    wrote on last edited by
    #1

    Hi guys... I've created a setup project using VS.NET. It works fine, change some registry keys, create my database (using my installer class), creates some IIS virtuals dirs. The problem is that I need to force the machine to reboot after the installation has been completed. Does anyone know how to to this ? Is there any parameter I can change in my installer class to do this ? thanks in advance Mauricio Ritter - Brazil Sonorking now: 100.13560 MRitter
    English is not my native language so, if you find any spelling erros in my posts, please let me know.

    H 1 Reply Last reply
    0
    • M Mauricio Ritter

      Hi guys... I've created a setup project using VS.NET. It works fine, change some registry keys, create my database (using my installer class), creates some IIS virtuals dirs. The problem is that I need to force the machine to reboot after the installation has been completed. Does anyone know how to to this ? Is there any parameter I can change in my installer class to do this ? thanks in advance Mauricio Ritter - Brazil Sonorking now: 100.13560 MRitter
      English is not my native language so, if you find any spelling erros in my posts, please let me know.

      H Offline
      H Offline
      Heath Stewart
      wrote on last edited by
      #2

      I just covered this a day or two ago (searching first is always a good idea). Set the REBOOT property (must be all upper-case) to Force. See the Windows Installer SDK for more information. Since VS.NET's setup projects suck, you'll have to download Orca (part of the Windows Installer SDK, which is part of the Platform SDK) and make the changes post-build. Just open the MSI package, find the Properties table, and add said property. You could also do this using a custom action, but it's quite a bit of overhead for a such a simple task.

      -----BEGIN GEEK CODE BLOCK----- Version: 3.21 GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++ -----END GEEK CODE BLOCK-----

      M 1 Reply Last reply
      0
      • H Heath Stewart

        I just covered this a day or two ago (searching first is always a good idea). Set the REBOOT property (must be all upper-case) to Force. See the Windows Installer SDK for more information. Since VS.NET's setup projects suck, you'll have to download Orca (part of the Windows Installer SDK, which is part of the Platform SDK) and make the changes post-build. Just open the MSI package, find the Properties table, and add said property. You could also do this using a custom action, but it's quite a bit of overhead for a such a simple task.

        -----BEGIN GEEK CODE BLOCK----- Version: 3.21 GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++ -----END GEEK CODE BLOCK-----

        M Offline
        M Offline
        Mauricio Ritter
        wrote on last edited by
        #3

        Heath Stewart wrote: You could also do this using a custom action, but it's quite a bit of overhead for a such a simple task. Actually I already have a installer class with custom actions in my setup project, it would be easier to insert the property there, I just don't know where to insert it. I tryed the Context.Parameters collection but it didn't work. Any ideias ? Mauricio Ritter - Brazil Sonorking now: 100.13560 MRitter
        English is not my native language so, if you find any spelling erros in my posts, please let me know.

        H 1 Reply Last reply
        0
        • M Mauricio Ritter

          Heath Stewart wrote: You could also do this using a custom action, but it's quite a bit of overhead for a such a simple task. Actually I already have a installer class with custom actions in my setup project, it would be easier to insert the property there, I just don't know where to insert it. I tryed the Context.Parameters collection but it didn't work. Any ideias ? Mauricio Ritter - Brazil Sonorking now: 100.13560 MRitter
          English is not my native language so, if you find any spelling erros in my posts, please let me know.

          H Offline
          H Offline
          Heath Stewart
          wrote on last edited by
          #4

          You can't, actually. .NET Installer classes have nothing to do with Windows Installer, Windows Installer is just able to run them as custom installer actions. I was talking about native custom actions that you'd have to write in C/C++ (with C-style functions). The easiest way is to install Orca and edit the MSI yourself. Just go to mdsn.microsoft.com and go to downloads. Click Platform SDK but only install the Windows Installer SDK. It will install only a few required components from the PSDK itself. Legally, I cannot just send you the installer for Orca but it is an invaluable tool and is worth the download if you're messing with installer packages.

          -----BEGIN GEEK CODE BLOCK----- Version: 3.21 GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++ -----END GEEK CODE BLOCK-----

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups