This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Check if admin before prerequisites installation
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 29, 2010
04:45 AM
Check if admin before prerequisites installation
Hi,
How can i prevent starting installer by someone who is not an administrator? I noticed that there is a Require Administrative Privileges property in the Summary Information Stream. WHen i start the installer as a non-administator "Install Program as Other User" window pops up. Now I have an option to either run the installation as a logged on user (non-administator) or a run as selected used (eg.Administrator).
How not to give the end user option to run the installation as a non administrator user (show error and leave the installer)?
As far as I know I cannot call CA before prerequisites (setup.exe)
I am using Basic MSI project type.
Regards!
How can i prevent starting installer by someone who is not an administrator? I noticed that there is a Require Administrative Privileges property in the Summary Information Stream. WHen i start the installer as a non-administator "Install Program as Other User" window pops up. Now I have an option to either run the installation as a logged on user (non-administator) or a run as selected used (eg.Administrator).
How not to give the end user option to run the installation as a non administrator user (show error and leave the installer)?
As far as I know I cannot call CA before prerequisites (setup.exe)
I am using Basic MSI project type.
Regards!
(6) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 29, 2010
08:24 AM
In the prerequisite editor you can add "This prerequisite require Admin Privileges" under Behaviour tab.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 29, 2010
09:06 AM
Hi,
Thank you for the response. I did a test with "This prerequisite require Admin Privileges" ticked on (default behaviour). The setup.exe allowed non-administrator user to launch installer and its prerequisistes even though "This prerequisite require Admin Privileges" checkbox was selected. Do you know why?
Ideally, I would like to display end user a message and exit installer before a window with prerequisistes is displayed.
Thank you for the response. I did a test with "This prerequisite require Admin Privileges" ticked on (default behaviour). The setup.exe allowed non-administrator user to launch installer and its prerequisistes even though "This prerequisite require Admin Privileges" checkbox was selected. Do you know why?
Ideally, I would like to display end user a message and exit installer before a window with prerequisistes is displayed.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 29, 2010
09:14 AM
Hi,
THat is what help file says about "This prerequisite require Admin Privileges"
NOTE
This setting applies to installations that are run on Windows Vista systems. Earlier versions of Windows ignore this setting.
I need a solution for OSs like XP, Vista and 7. SO is there a way to detect if user is an admin and if not abort the installation, before prerequisistes are installed or even displayed?
Regards!
THat is what help file says about "This prerequisite require Admin Privileges"
NOTE
This setting applies to installations that are run on Windows Vista systems. Earlier versions of Windows ignore this setting.
I need a solution for OSs like XP, Vista and 7. SO is there a way to detect if user is an admin and if not abort the installation, before prerequisistes are installed or even displayed?
Regards!
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 18, 2011
06:40 AM
I have the same problem, on Windows 7 OS my installer runs the prerequisite installation under non-Admin account, "The prerequisite requires administrative privileges" option is set in prerequisite editor.
InstallShield 2009 Premiere.
InstallShield 2009 Premiere.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 18, 2011
12:10 PM
if the 'Require admin privileges' doesn't work then use a wrapper (C#) to your exe to check if user is admin based on which you can launch your setup.exe
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 19, 2011
04:13 AM
rrinblue22 wrote:
if the 'Require admin privileges' doesn't work then use a wrapper (C#) to your exe to check if user is admin based on which you can launch your setup.exe
thank you. I'm going to create my own hidden prerequisites that will check admin privileges and exit from installation if user is not admin.
The next question is how to break installation, what code should my .exe return to let InstallShield know it should break?
![](/skins/images/8C9D13A71C7F7695F3262372C0172D68/responsive_peak/images/icon_anonymous_message.png)