Question : give Administrative Privilege App by command

Hi, I need to execute an app and I would like to know how can I give the "run as administrator" from console.

I've noticed that in windows vista/7, in properties program window is a checkbox that allows (see picture) it, but... is there a way to do that from command prompt?

Many thanks.
Attachments:
 
Run as Administrator Property
Run as Administrator Property
 

Answer : give Administrative Privilege App by command

Ok. So the question is: is the user already a member of the group administrators? If yes, the best way would be to setup a scheduled task and have it run with highest privileges. Afterwards, the user could doubleclikck a shortcut to this task and the app will start with highest privileges without any prompt for consent.
A second possibility is to install a shim and use the option runas invoker, see http://www.microsoft.com/downloads/details.aspx?FamilyID=F3B46BA6-0EF2-47DB-AAEC-ED786109E030&displaylang=en

However, if he ain't a member of the group administrators, he will have to know the password of the account administrator (or have it at least delivered encrypted) and has to use a batch with runas.
Random Solutions  
 
programming4us programming4us