PS script to change printers and check for default

 We have a large project of renaming printers due to some linux devises that do not agree with our naming convention. I am new to ps so looking for some direction.
Our current printers are say 'print$1' and we are changing to 'print1' basically just removing the dollar sign.
We have batch files for the helpdesk for new imaged machines so they will get the new names, no problem but for the people that have been here, how can I create a script that will do the following:
1. allow me to put old printer > replace with new printer
2. detect if old printer is default and make new printer default.
3. only affect the printers that are currently installed on the pc
note we have multiple locations and alot of print servers. 
thank you for your help

gaff-
I believe he wants to rename the printers on the client workstation. Group Policy can do that very easily
You can also add to your ProintManager script to have it generate the GP objects and add the users or computers to them.  Most of the time is is easier to just use ProntManager GUI unless you have hundreds of printers  If it is only a dozedn then
a non-scripter would be better off running the GUI.
We moved about 30 printers for 100 accounts in about one hour the first time we set up PrintManager.  This included an upgrade to 64 bit drivers which was the biggest issue. A rename is very much easier.  I can rename 30 probters with the GUI in
about 2 minutes.
It is resetting the client systems that is the issue.  If they are beoing set by GP or through a login script then this, too, is easy.  If they are just attached in different ways then I recommend that Group Policy is the only way to reset them
without spending a month trying to design a script that will work for all systems.
If this is for a WS2003 spooler then you can still use Group Policy Preferences it you install the AD updates or have WS2008 domain controllers.
Placing all printers under PrintManager control is the absolute best method.
If all printers are not Windows printers - (Unix spolers or JetDirect/Network) then you will have to create a script that can find every pronter and rename it on every system.  This will be very difficult to do and will likely take quite a while to
accomplish in a large network.
GP can install printers at the machine level and update drivers.  This will work well except if you are using non-Windows compliant printers.  I have never had this scenario work smoothly on  an older network.  This is one reason why
I do everything I can to force Admins to use PrintManager for all printers WIndows and Unix.  We also try to be sure the location awareness is enabled and that all locations are tagged in AD.  This allows users to browse easily for local and remote
printers.  We set initial default but user4s are always allowed to change the default if they want and know how.  Users are allowed to print to all "group" printers and departmental printers but not to personal printers.  In some cases
all users in a group can print to each others personal printers.
I am now working on getting wireless printers set up for use by visitors, guests and salespeople.  Every group should have a wireless printer and know the hidden SSID.  I notice that many universities and hospitals are now doing this for the convenience
of visitors. I can priont from my phone almost everywhere I go lately.
Use PrintManager.  It will save you a lot of trouble.  Once set up PowerShell can script everything very nicely.  Gaff's code will always be the easier way to do most things.
If you look in the repository/Gallery you will see many PowerShell PrintManger scripts and tools. -
I should also note that Gaff's suggestion to use WMI will only work in a login script and will not work well on system connected printers which will have to be done remotely.  Again, it all depends on how your environment is set up.
¯\_(ツ)_/¯

Similar Messages

  • What can I do to change the sound of a track in garageband?  It is "stuck" on electric piano setting and will not change. I've tried restarting, restoring sound library, full key reset, and checked for updates.

    What can I do to change the sound of a track in garageband?  It is "stuck" on electric piano setting and will not change. I've tried restarting, restoring sound library, full key reset, and checked for updates.

    Hi
    In iMovie'11 (version 9.0.x)
    on top menu row - Apple/iMovie/File/Edit/Cut (Can vary dep. on language - in Swedish Apple/iMovie/Arkiv/Redigera/Klipp . . . )
    down Cut menu - Slow playback/Raspid Playback/Re-play in Slow Motion and onvards
    Here one can select the Pre-Set speeds
    Are you familiar with getting 'inspector' to run?
    No - but I guess that Double Click on clip/sequense or ctrl-Click on it might open it.
    Yours Bengt W

  • Help!! Auto-Deploy and Check For Updates in an OPMN-managed instance

    I'm trying to use the auto-deploy and check for updates functions in an OAS 10.1.0.3 but I can not make it work.
    I don't Know if this functions are only availables for a standalone OC4J instance.
    Can anyone help me??
    Thanks!!! and sorry for my poor english.

    Auto-Deploy is not really designed for an OPMN managed instance -- in earlier releases, this would not even work correctly since deployments where stored in the DCM subsystem and any subsequent configuration changes made via DCM would overwrite the config and you'd lose the "auto-deployed" application.
    In 10.1.3.x where DCM is no longer in the picture, and the auto-deploy polling is a function of Oc4J itself, it may work. Be aware that this is not something that is tested in OPMN managed environments.
    What configuration changes have you made?
    You need to ensure you have modified server.xml so the attribute check-for-updates="all" and you've added the attribute application-auto-deploy-directory and have it pointing at a directory to watch.
    -steve-

  • Unable to Determine the Change Date and Time for records in infotype 2011

    Hi Everyone,
    We need to know on when the clock-in and clock-out records were interfaced to SAP in infotype 2011.
    The change date/time field in infotype 2011 is blank/not populated. Hence, we're unable to determine on when the clock-in records were updated in infotype 2011.
    It is not possible to get the audit logs for infotype 2011 as it is switched off.
    We found this table TEVEN and just the same thing, the field "change on" is blank.
    Kindly help us on how we can determine the change date and time for records in infotype 2011.

    Hi Prasad,
    Here's the scenario.
    On June 3, it was reported that staff's clock-in record on june 1, 7:00AM is missing in infotype 2011.
    However, when I checked infotype 2011, the record is there.
    So, they are now asking me on when this record was updated in infotype 2011 as they are thinking that there might be some delays in sending of the data to SAP.
    The created on and created at in table TEVEN shows the same, june 1, 7:00AM which seems to be not true as on june 3, it was reported to be missing.
    Can you help further on this?

  • I have rented a movie from apple tv but cant watche it,it says go to itunes store and check for rentals, but its just lowding

    just rented a movie from my apple tv, accidently got out, and cant play it back, it says that go to itunes store and check for rentals, but it just show lowding and lowding                              please some one help, how can i play it back????????????????

    Welcome to the Apple community.
    A number of people have reported similar issues recently, many appear to have found a discrepancy of some kind in their account settings and making changes to these settings or simply resetting them has resolved the matter.
    Check your account details are correct, check that you are using the correct details for Location, Region and Time Zone. You may want to change these settings and then change them back to see if that helps.
    You might also try logging out of and then back into your iTunes account (Settings > iTunes Store > Apple ID’s > Sign Out) and restarting your router. (Some have reported that after doing this, they need to check for rentals even though it may report that there aren’t any, after which rentals once again appear in the ‘movies’ feature)
    Rentals should appear under their own heading in the ‘Movies’ feature, you might also check at Settings > iTunes Store > Check For Rentals.

  • Cancellation / Reversal of Credit memos and Check for payment

    I have few cases where the credit memos and check for payment documents have been keyed with an incorrect posting date.
    What should be best approach to reverse these transactions.

    Hi Somchitra,
    in such situations ideally you would use the cancellation document standing on the original document, alas, a credit memo has no target document.
    You will need to create an invoice with exactly the same data as in the credit memo & then internally reconcile these transactions. If the credit memo was in itself generated from an invoice, you need to cancel that reconciliation first. After that you re-create the credit memo with exactly the same data, just with the correct dates.
    To cancel the cheques for payment you need to cancel the payment itself with the original document date & 'Cancelled' will be put in the 'Remarks' on the cheque.
    You will then need to recreate the payment with the correct dates.
    If you have already confirmed the printing of the cheque, you'll need to issue a new cheque number & destroy the printed copy, if it hasn't been printed, you can select the appropriate number in the 'Cheque number confirmation' window.
    As always when correcting transactions, please keep an eye on the stock transactions & make sure they are correct. Also, for auditing purposes, always enter an approriate text in the 'remarks'.
    All the best,
    Kerstin

  • Change username and password for PGW2200 ..... ????????....................

    Dear how i can change username and password for PGW2200?
    can give the procedures?
    thanks,

    it is ok ....
    thank you....
    i have now this issue:
    i need to add new E1 to be in the same trunk for previous E1 which is for Abdali. new E1 will not have signal it depeneds at old one timeslot.
    i used this for new E1:
    prov-add:nailedtrnk:name="1033",srcsvc="ss7p-jtc-abdali",dstsvc="naspath1-abdali",srcspan="ffff",dstspan="0",srctimeslot="33",dsttimeslot="33",spansize=31
    for old one this:
    prov-add:nailedtrnk:name="1002",srcsvc="ss7p-jtc-abdali",dstsvc="naspath1-abdali",srcspan="ffff",dstspan="0",srctimeslot="2",dsttimeslot="2",spansize=30
    ============================
    at AS5400 i used to add new E1:
    controller E1 7/2
    framing NO-CRC4
    pri-group timeslots 1-31 nfas_d primary nfas_int 1 nfas_group 0
    Is this true or there are other commands i should use?
    OLD E1 is configured as:
    controller E1 7/0
    framing NO-CRC4
    channel-group 0 timeslots 1
    pri-group timeslots 2-31 nfas_d primary nfas_int 0 nfas_group 0
    description Connection to Abdali
    interface Serial7/0:0
    no ip address
    encapsulation ss7
    channel-id 0
    interface Serial7/0:15
    no ip address
    encapsulation hdlc
    isdn switch-type primary-ni2c
    isdn incoming-voice modem
    isdn map address . plan isdn type network
    isdn rlm-group 0
    no isdn send-status-enquiry
    isdn negotiate-bchan resend-setup
    isdn bchan-number-order ascending
    no cdp enable
    any help please for correct commands i shall use? please see attached file for details.

  • I am unable to change username and password for wifi network

    unable to change username and password for wifi network

    Thanks, this solved my problem. Network kept demanding username; I guess it's different from the computer ID I use. Whatever, it wasn't easy to find the network listed, but by trial and error, I found it, highlighted it, and pressed delete key. Now the network only asks for password, which I knew, and I'm on. Great advice. But why computer was configured to do that in the first place is why I prefer PC to my wife's inscrutable macbook pro.

  • TS3276 can anyone help on the following please. When I have been away from the office for a few days and check for emails it only supplies the most recent 100 emails and the ones before that are never received. thanks

    can anyone help on the following please. When I have been away from the office for a few days and check for emails it only supplies the most recent 100 emails and the ones before that are never received. thanks

    Does your server have a limit?

  • HT1688 I can not restore and upgrade my Iphone 4. When i plug in to computer itune's restore and check for update buttons are not active.

    I can not restore and upgrade my Iphone 4. When i plug in to computer itune's restore and check for update buttons are not active. What is that mean?

    Razmee,
    Guess what? After posting, I read another thread on this topic where someone said they went to an Apple store and the tech person there added the optional username and password in the Outgoing Mail Server boxes, and then reset the phone again. Although I had tried resetting and restarting a few times today, I had NOT reset it after entering the username and password into the optional fields.
    When I entered my username and password into the optional fields, the iPhone entered checks (ticks) to the right of every entry; it had not done this earlier. (I didn't reset at this time, and the outgoing mail would still not transmit).
    So just now, I reset it and the outgoing email was sent!
    Thanks to you and this forum, it's a great ending to a few frustrating days.
    I hope this message helps others. Not only does everything have to be entered correctly in the respective boxes; but once everything is entered and you press the "Done" button, every box should then have a check mark next to it and then you must reset the phone.

  • I have just rented a film and clicked the menu button instead of pause. When I go back to the film to rent again it says I have already rented this go to settings and check for downloads. But there is no download option in settings?

    I have just rented a film and clicked the menu button instead of pause. When I go back to the film to rent again it says I have already rented this go to settings and check for downloads. But there is no download option in settings?

    It does... Apple TV has a problem with the assignment to the itunes account after updating. Restore to factory settings or unlog and news login to the itunes store helps to see the rented/downloaded film(s).

  • SCCM 2012 R2 changing date and time for patching software update groups

    I recieve this error when changing date and time for software update group. worked fine yesterday before patches to the server were applied last night. we removed patches but still get error below. Any help would be great.
    ConfigMgr Error Object:
    instance of SMS_ExtendedStatus
    Description = "Property array AssignedCIs exceeded the max allowed";
    ErrorCode = 1078462259;
    File = "e:\\nts_sccm_release\\sms\\siteserver\\sdk_provider\\smsprov\\sspupdatesassignment.cpp";
    Line = 94;
    Operation = "PutInstance";
    ParameterInfo = "";
    ProviderName = "ExtnProv";
    StatusCode = 2147749889;
    Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlQueryException
    The SMS Provider reported an error.
    Stack Trace:
    at Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlResultObject.Put(ReportProgress progressReport)
    at Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlResultObject.Put()
    at Microsoft.ConfigurationManagement.AdminConsole.SmsDialogData.Put(IResultObject resultObject, List`1 resultObjectsPut, Boolean retainLock)
    at Microsoft.ConfigurationManagement.AdminConsole.SmsDialogData.Put(Boolean retainLock)
    at Microsoft.ConfigurationManagement.AdminConsole.DialogFramework.Forms.SmsPropertySheet.Put(ActionTrigger trigger)
    System.Management.ManagementException
    Generic failure
    Stack Trace:
    at Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlResultObject.Put(ReportProgress progressReport)
    at Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlResultObject.Put()
    at Microsoft.ConfigurationManagement.AdminConsole.SmsDialogData.Put(IResultObject resultObject, List`1 resultObjectsPut, Boolean retainLock)
    at Microsoft.ConfigurationManagement.AdminConsole.SmsDialogData.Put(Boolean retainLock)
    at Microsoft.ConfigurationManagement.AdminConsole.DialogFramework.Forms.SmsPropertySheet.Put(ActionTrigger trigger

    no it is the final version... is working today after cleaning up database... is working now...thanks
    Hello Robert,
    would you please give some more informations, as I have the same issue and don't get what you mean bye "cleaning up databases".
    Regards ooGDoo
    ooGDoo

  • HT1657 I rented a movie and accidentally hit the menu button and now I can figure out how to go back and watch it . When I try to press rent again it says you have already downloaded this movie go to settings and check for downloads but I can find it.

    I rented a movie and accidentally hit the menu button and now I can figure out how to go back and watch it . When I try to press rent again it says you have already downloaded this movie go to settings and check for downloads but I can find it download in settings.

    I had the same issue with my apple tv 3rd generation. I rented Sinister and selected the "rent and watch now" option. Half way through the movie I accidentally pressed the menu button. When I looked for the rented movie on my apple tv I could not find it. Not even above the movie pannel where "purchased" and "top movies" comes up on the main menu. the apple tv suggests to go to settings>downloads but I don't have that option. I did go to settings> itunes store> check rentals but that didnt work either. It took too long to even check. Thank you because this SOLUTION worked great.
    SOLUTION: How to reset apple tv 3 3rd generation to view rented movies:on the apple tv remote: press and hold "menu" to go to the main menu. Select SETTINGS> GENERAL >RESET >RESET ALL SETTINGS. After the apple tv resets, input all your information again and your rented movies should be visible when you cruise above the "movies" section. THANK YOU!!
    Apple needs to solve this issue because honestly it took me 3 hours and a half to watch a movie that only lasted 2 BECAUSE I wast trying to solve the issue, reseting and all. blahh.

  • When the iPhone 4 with IOS 5 is connected by cable to iTunes and check for update results in Error 1630. plz help me

    When the iPhone 4 with IOS 5 is  connected by cable to iTunes and check for update results in Error 1630, plz help me to update plz

    My Iphone 4 crashed yesterday after a restart and upload of OS 5.0, it will only partially sync.  It's not transferring any of my music or ringtones.  They still appear when I click open the sync screens on ITunes, but I don't seem to have an Ipod function and only one of my personalized ringtones transfers on the actual phone.

  • HT1339 My ipod classic fails the sync test on Windows 7. help say go to summary tab and check for updates. I cannot find a summary tab

    My ipod is failing the sync diagnostic on my Windows 7. The troubleshooting guide say go to the Summary Tab and "check for updates" I can't find a summary tab. I have no problem sync with windows vista.

    chicx wrote:
    This is the third time of writing this on your Apple Support Communities!
    Not with your current user id.
    Far too much uneccesary information in your post, which only confuses things, a vast amount!
    Let's start with iTunes.
    Have you updated iTunes to 11.1.5, because the previous version did appear to have an issue about seeing iPods?
    With iTunes 11.1.5 installed, look in Edit/Preferences/Devices, (or use the ALT key, followed by the E key and then the F key) and make sure that the box named Prevent iPods, iPhones and iPads from syncing automatically does not have a tick in the box.
    Once you have doen those two things, check to see if the iPod is seen by iTunes.
    chicx wrote:
    By the way, what does IOS mean? (I thought IO stood for operating system, but am flummoxed by the S on the end.
    Really?
    OS stands for Operating System. (In computer speak, IO means Input/Output.)
    iOS originally stood for iPhone Operating System, but it now refers to the iPod Touch and iPhone. The iPod Classic, which you have listed in your profile as your iPod, does not use iOS.
    I assume that you have been listening to the Podcast in your iTunes on the computer as you cannot transfer it to your iPod. It's what I'd do.

Maybe you are looking for