![]() |
#1 |
Junior Member
Join Date: Feb 2006
Location: suzhou,china
Posts: 28
|
![]()
My program need a dirver to run, so it must run as a administrator, but how can i set my program "run this program as a administrator"?
Does NSIS support this function? ths |
![]() |
![]() |
![]() |
#2 |
Senior Member
Join Date: Dec 2004
Location: Turkey
Posts: 447
|
Make sure you use NSIS version v2.22 or higher and then add the line blow to your script...
RequestExecutionLevel admin For the rest, see your own quote ![]() "Just do it" |
![]() |
![]() |
![]() |
#3 |
Junior Member
Join Date: Feb 2006
Location: suzhou,china
Posts: 28
|
thanks a lot
|
![]() |
![]() |
![]() |
#4 |
Junior Member
Join Date: Feb 2006
Location: suzhou,china
Posts: 28
|
RequestExecutionLevel admin
using this command can elevate setup.exe's privileges really, but can't elevate my program. After installed, it can't run unless manually enable the option of "Run as a administrator". |
![]() |
![]() |
![]() |
#5 |
M.I.A.
[NSIS Dev, Mod] Join Date: Oct 2001
Location: Israel
Posts: 11,343
|
Embed a manifest in your program as well. For more details, see MSDN.
http://msdn.microsoft.com/library/en...asp?frame=true NSIS FAQ | NSIS Home Page | Donate $ "I hear and I forget. I see and I remember. I do and I understand." -- Confucius |
![]() |
![]() |
![]() |
#6 |
Senior Member
|
Just to be sure,
If I use "RequestExecutionLevel admin" I do not need the .manifest file anymore ? I am talking about the setup file made in NSIS, not the program it installs. Thanks. |
![]() |
![]() |
![]() |
#7 |
M.I.A.
[NSIS Dev, Mod] Join Date: Oct 2001
Location: Israel
Posts: 11,343
|
That's correct. That command adds the manifest.
NSIS FAQ | NSIS Home Page | Donate $ "I hear and I forget. I see and I remember. I do and I understand." -- Confucius |
![]() |
![]() |
![]() |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|