Link to home
Start Free TrialLog in
Avatar of Garry Shape
Garry ShapeFlag for United States of America

asked on

Create list of distribution groups with incremental numbers

I'm looking to find a way to create distribution groups in Exchange Powershell and each group will end with a number up until 50.

The base group name will be "TestGroup" followed by 001, 002, 003 and so on until 050.
How could you do it in powershell to create the distribution group automatically with the numbering, without having to pre-type it out and import as a text/csv?    

New-DistributionGroup -Name "TestGroup001" -OrganizationalUnit "contoso.com/Users" -SamAccountName "TestGroup001" -Type "Distribution"

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Mlanda T
Mlanda T
Flag of South Africa image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Garry Shape

ASKER

MLanda thanks what is the {0:000} is that an operator? ?