Posted On August 26, 2021

Quick PowerShell Cmdlet to Move Computer Object

kimconnect 0 comments
blog.KimConnect.com >> Windows >> Quick PowerShell Cmdlet to Move Computer Object
$computername='SomeComputerName'
$targetOU='OU=Computers,DC=kimconnect,DC=com'
Move-ADObject -Identity (Get-ADComputer $computername).objectguid -TargetPath $targetOU

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

PowerShell: Windows Performance Benchmarking

There are many 3rd party performance benchmark tools for Windows 10. Out of convenience, PowerShell…

PowerShell: Download Dot Net 4.7.2

# Illustration: download Dot Net 4.7 Run-time from behind a proxy and showing progress barfunction…

PowerShell: Create Registry Keys within Windows Localhost

# createRegKey.ps1 $regKeys=@( @{ hive='REGISTRY::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Google\Chrome'; name='ChromeCleanupEnabled'; value=0 } @{ hive='REGISTRY::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Google\Chrome'; name='ChromeCleanupReportingEnabled'; value=0 } ) function…