Account.Rename
Top  Previous  Next


Renames server or workstation user account

Category
SamAccount

Script section
[Batch], inside Data.Loop..EndLoop statement

Account.Rename
SamAccountNameColumnVariable, NewSamAccountNameColumnVariable

SamAccountNameColumnVariable
Format: "%colX%", X = Column in [Data] section with existing SamAccountNames  

NewSamAccountNameColumnVariable
Format: "%colY%", Y = Column in [Data] section with new SamAccountNames  
See Account.Create for SamAccountName allowed length and characters  

Other parameters
This command is executed on the current machine in the [Machines] section.  

Example
Rename accounts listed in column 2 to names listed in column 3

Account.Rename %col2%, %col3%

Full example
Rename SamAccounts