/build/static/layout/Breadcrumb_cap_w.png

How can I run an elevated command prompt for a batch file?

I am trying to install a local IP printer through a script with K1000.  We have ran into a roadblock because the script is giving us Access is Denied problems when running from KACE.

However, when I copy the script down to the computer and run it from the same user, the script runs fine.

We have tried to change Windows Runas options to reflect something other than Local System, but when we do that the script refuses to run at all.

I am thinking that we are having problems running the command prompt in an elevated state to run correctly.  What is the correct procedure to complete this task?  I am newer to scripting and the K1000.



Also, if there is a better option to install local IP printers without the use of a print server through KACE I'd be willing to give that a shot as well. 

1 Comment   [ + ] Show comment
  • The odd thing about all of this, is that I sent the script out to a computer logged in as administrator and it still failed. When I switch the options in kace to run as logged-in user the script hangs and doesn't complete or actually get sent from the k1000 to the computer, but if I use local system it gets sent almost instantaneously. It's very odd. I will try the Driver Installation Policy method and see what happens. - ZCSJfisher 9 years ago

Answers (2)

Posted by: SMal.tmcc 9 years ago
Red Belt
0
IP printers are a per user/profile thing so you need to run that as logged-in user
Posted by: jknox 9 years ago
Red Belt
0
It appears that you can set the Driver Installation Policy to allow this:  https://social.technet.microsoft.com/Forums/windows/en-US/df21d2c2-c2d4-4107-bfe3-bf8c5a1cd946/install-printer-without-being-administrator

If that works, you should be able to then use a Kscript running as logged in user to install the IP printer.

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ