Sign in to follow this  
Followers 0
Arthur L

Printer script help

2 posts in this topic

Hi guys this is my first post here.

I need help on a script. What this actually does is to set some printers in our company to print at default monochrome.

What I did is to manually set the printing preferences of the printer to print at default monochrome then I capture the settings and dump it into a .dat file.

The script is shown below:

Runwait (@systemdir & '\rundll32 printui.dll,PrintUIEntry /Sr /n "printername" /a "\\server\share$\printername.dat"')

This script works fine when executed directly in my PC.

Now, in our company, we use Altiris deployment console to take care of deploying the script into 1000 computers. When I deploy the script, it executes, but instead of modifying the printer settings for the users, it only modifies the "administrator" account printer settings.

Now, is there a way for this script to run in the currently logged on user environment? It is worth noting that they only have user priviledges.

Another way I see it is to run this script so that it modifies the Default User profile in windows.

Anyone has suggestions?

Thanks.

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Maybe?:

RunAs()

Initialise a set of user credentials to use during Run and RunWait operations. 2000/XP or later ONLY.

You can use it to restart the script as a specific user.

Anyway. Welcome to the forum. :P

Edited by SolidSnake

HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code.

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0