Community Forums
Page 1 of 2 12 LastLast
Results 1 to 5 of 10

Thread: How to set an executable property to 'Run as Administrator'?

  1. #1
    Join Date
    Nov 2006

    Question How to set an executable property to 'Run as Administrator'?

    I have an InstallScript MSI project.

    On Windows Server 2008, there is a check box in the executable properties dialog to run it as an administrator.

    Is there a way to do this from Install Script so that the user does not have to do this?


  2. #2
    Join Date
    Jan 2002
    Windsor, CT 06095 USA
    I don't know of a way to do this in InstallShield. We create a manifest file and name it the same as the exe file we are trying to force Run as Admin on. For example for a file named APP.EXE the manifest would be named APP.EXE.MANIFEST. This file is placed in the same folder as the EXE and contains the following XML code that instructs Windows how to handle the file.

    <?xml version="1.0" encoding="utf-8" ?>
    <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
    	<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
    				<requestedExecutionLevel level="requireAdministrator" />
    Eric Siemiatkaska
    SS&C Technologies, Inc.

  3. #3
    Join Date
    Jan 2008

    Calling .dll File Function

    We can use the manifest file for exe, but how about if I want to call a function from dll? In Vista, it is required to run as administrator as the function need to access the registry.

  4. #4
    Join Date
    Jul 2003
    North Kingstown, RI, USA
    Is this a DLL that you compile in house? IF so why not have Visual Studio create and embed the manifest file for you? In VS2005 I just open the project, right click on the project in the Solution Explorer view, choose properties and then modify the manifest properties.
    Dan Lee

    Release Engineer

  5. #5
    Join Date
    Nov 2006
    I did update the manifests (wherever I could) of all our executables.

    But for some, the build server won't let me do it. So, I was wondering for such exes, if I could do it from the install.

    Any suggestions will be much appreciated.


Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts