2 SCCM Powershell Scripts
1. Getting a list of devices from a device collection using powershell:
Get-CMDevice -CollectionName <your collection name> | Select Name
2. Connecting to SCCM Using PowerShell:
Import-Module "C:\Program Files (x86)\Microsoft Configuration Manager\AdminConsole\bin\ConfigurationManager.psd1"
New-PSDrive -Name <yoursitecode> -PSProvider "AdminUI.PS.Provider\CMSite" -Root "<your SCCM server's FQDN>" -Description "SCCM Site"
CD <yoursitecode>:
/image%2F0881799%2F20140610%2Fob_a8c7fe_logo2.jpg)
Commenter cet article