Creating your own objects with PSCustomObject

PSCustomObject offers us an excellent way to create structured data in PowerShell. According to the documentation, [pscustomobject] is a type accelerator. Type accelerators “allow you to access specific .NET framework classes without having to explicitly type the entire class name”. The full class name for PSCustomObject is System.Management.Automation.PSObject, which means PSCustomObject is just an alias […]

Moving users or computers in AD with the Move-ADObject cmdlet

According to the official documentation, Move-ADObject “Moves an Active Directory object or a container of objects to a different container or domain”. The straightforward noun-verb structure of PS also suggest what you can do with it. Let’s review the syntax: Both -Identity and -TargetPath are obligatory parameters. Regarding -Identity, we can use a distinguished name […]

| Theme: UPortfolio