Share via

How to run msi with 'Run as administrator"

Anonymous
2009-06-22T07:00:03+00:00

Help needed in running a windows application on Vista/Win7 machine.

Issue1: I have created an MSI for the windows application which will create few registry values depending on the selections done by the user while installing the application.

The Issue is; when I run the MSI in Server2003/XP machines it is creating the registries perfectly but when the same MSI was ran in Vista/Win7 machine it is not creating the registries.

Hope this is an issue with the security in Vista machines. Please kindly suggest me what can be done.

Issue2: The windows application will create a log file into the location where the application has been installed (by default application gets installed in the “C:\program files\” folder).

The Issue is; when the application is run in Server2003/XP machines the log file is getting created, but when the same was ran under the Vista machine then it is throwing an exception that access to the path c:\Program Files..\command.log file is denied.

I also tried

I am member of Admin gruop and  I ran the command prompt with "Run as administrator" and then from there I have pointed to the MSI and ran it, but still it is not creating the values in the registries.

Please suggest me some work around for the above issue

Windows for home | Previous Windows versions | Apps

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

  1. Anonymous
    2009-06-22T07:36:22+00:00

    This might help?

    MsiRunAsAdmin

    MSI "Run as administrator" Context Menu for Vista

    http://www.symantec.com/connect/downloads/msi-run-administrator-context-menu-vista

    Can you change .msi to .zip, and via WinZip etc. extract the files and find a Setup.exe to right-click on?

    Something like this might work?

    Run the CMD prompt as Admin, then the following:

    msiexec  /a your.msi

    HOW TO: Take Ownership of a File or Folder in Windows XP (or Vista)

    http://support.microsoft.com/kb/308421/en-us

    Error Message: "Access Is Denied" When You Try to Open NTFS File System Folders

    http://support.microsoft.com/default.aspx?scid=kb;EN-US;Q823306#appliesto

    "Enable Microsoft Installer logging and Windows Update verbose logging -

    For computers that are running Windows Vista and Windows Server 2008"

    You receive error code 0x80070643 or error code 0x643 when you use the Windows Update or Microsoft Update Web sites to install updates

    http://support.microsoft.com/kb/958052#appliesto

    1 person found this answer helpful.
    0 comments No comments

9 additional answers

Sort by: Most helpful
  1. Anonymous
    2015-06-19T13:15:54+00:00

    Windows 7:

    1. On Start line, type CMD and when it appears on the menu, right click on it and select "Run as Administrator
    2. In File Explorer, hold SHFT and Right-Click on the MSI file, select "Copy Full Path"
    3. Go back to your command window and right-click, and select paste
    4. Edit the line to remove the quotes from the beginning and end of the line.
    5. Press enter and it will run as Admin.
    20+ people found this answer helpful.
    0 comments No comments
  2. Anonymous
    2013-10-01T07:07:47+00:00

    open cmd (in Accessories folder) as administrator, and run the msi from there.

    1 person found this answer helpful.
    0 comments No comments
  3. Anonymous
    2013-03-12T08:16:17+00:00

    Hello,

    One more method to try is right click while holding shift key, then you should have a run as option.

    Saladin.

    1 person found this answer helpful.
    0 comments No comments
  4. Anonymous
    2010-10-26T11:36:36+00:00

    We also had the same problem with the .msi files we were creating. It was very frustrating. After googling for a very long time we found a registry based solution which worked, we adapted it and came up with the following:

    http://www.sourcecodestore.com/Article.aspx?ID=10

    Once the Install_As_Administrator.Reg patch is applied, it makes any .msi file run with elevated permissions.

    0 comments No comments