Windows Server® 2012 Unleashed
by Rand Morimoto, Michael Noel, Guy Yardeni, Omar Droubi, Andrew Abbate, Chris Amaris
Using Snap-Ins
Snap-ins are used to show a list of all the registered PSSnapins outside of the default snap-ins that come with PowerShell. Entering the command Get-PSSnapin -Registered on a newly installed PowerShell system will return nothing, as shown in the following example:
PS C:\> get-pssnapin -registered
In most cases, a setup program will accompany a PowerShell snap-in and ensure that it becomes correctly registered for use. However, if this is not the case, the .NET utility InstallUtil.exe is used to complete the registration process. In the following example, InstallUtil.exe is being used to install a third-party library file called freshtastic-automation.dll:
PS C:\> & "$env:windir\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe" ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access