Link to home
Start Free TrialLog in
Avatar of MASWORLD
MASWORLDFlag for France

asked on

need batch file to run application as administrator privilege

Hi Experts
i have an application no working with all features except i run it as administrator however the user is a domain user
i need batch file to run this app as administrator without give the domain user admin password
ASKER CERTIFIED SOLUTION
Avatar of Jeremy Weisinger
Jeremy Weisinger

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of MASWORLD

ASKER

thanks
i already check this
but the some application reports not working except i run the app as administrator
EVEN I RUN THIS APP FROM ADMIN USER !!! must run as
You need to use PSEXEC to include the username and password, but be careful because any slightly tech-savvy users can view the file and see your admin password.

The command line would be structured like this:
psexec \\computername -u domain\user -p password "C:\appname.exe"

For more info on the PSEXEC command, refer to https://docs.microsoft.com/en-us/sysinternals/downloads/psexec
Thanks@ William Fulks
i can remember code with save credentials option can ask for the pass for first use only
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Jeremy Weisinger
Jeremy Weisinger

If you must then you can use compatibility mode to run the application elevated.
https://technet.microsoft.com/en-us/library/ff431742.aspx
Thanks all
@jeremy the process monitor app is awesome
@William it's working with second batch
Glad to help. :)