sumitd Posted August 14, 2013 Share Posted August 14, 2013 How do i run an exe file from a shared location (no password required) with administrator rights Location : <ip>softwaressetup.exe I want to execute it as "Run as administrator" Any suggestions? Link to comment Share on other sites More sharing options...
sumitd Posted August 14, 2013 Author Share Posted August 14, 2013 I have tried the RunAs() function. But in my case i don't need the username and password. Just access the shared location and run the file as administrator Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted August 14, 2013 Moderators Share Posted August 14, 2013 If you just want to run it with admin rights, and you're not having to provide the credentials of a different user, try adding #RequireAdmin at the top of your script. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
sumitd Posted August 16, 2013 Author Share Posted August 16, 2013 Thanks JLogan3o13 for the suggestion, I had already tried that in my script but no effect and I still have to manually do a "Run as Administrator" Any other suggestions? Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted August 16, 2013 Moderators Share Posted August 16, 2013 Yes, post your script so we can see exactly what you're doing "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now