How it works...
The process is straightforward. If you query the help information for the TypeName parameter of Remove-TypeData, you will notice that it accepts the type name input via the pipeline by property value as well as the property name. Recall the Understanding pipeline-enabled parameters recipe from Chapter 4, Passing Data through the Pipeline, and look at the object returned by Get-TypeData for more insight.
The Remove-TypeData cmdlet removes the type data from the current session. This removal is as ephemeral as type addition is. Therefore, the default types and formats are not permanently removed by the cmdlet; this is the reason why you can run this within PowerShell, without administrator privileges. Also, remember that the ...
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