Chapter 7 Quick Reference


Open table as spreadsheet

To

Do This

Delete users in an easy fashion

Modify the script you used to create the user, and change the Create method to Delete.

Commit changes to Active Directory when deleting a user

Nothing special is required. Changes take place when deleted.

Find country codes used in Active Directory and Computers

Use ISO 3166

Modify a users first name via ADSI

Add a value to the GivenName attribute. Use the SetInfo() method to write the change to Active Directory. Use the Put method to at least specify the sAMAccountName attribute if using Windows 2000 AD.

Overwrite a field that is already populated in Active Directory

Use the Put method.

Assign a value to a terminal server profile attribute after making a connection into Active Directory

Assign the value to the property. There is no need to use the Put method.

Read a text file and turn it into an array

Use the Get-Content cmdlet and specify the path to the file by using the path argument.




Microsoft Press - Microsoft Windows PowerShell Step by Step
MicrosoftВ® Windows PowerShell(TM) Step By Step (Step By Step (Microsoft))
ISBN: 0735623953
EAN: 2147483647
Year: 2007
Pages: 128
Authors: Ed Wilson

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net