Earlier this Spring, I launched a brand new operate referred to as Get-TypeMember. The operate is within the PSScriptTools module. I wrote about that launch right here. This command is a substitute for Get-Member that features extra particulars. The opposite day I pushed a brand new model that makes it simpler to determine properties which are enumerations.
The operate has a customized format file that highlights the enum properties. This characteristic won’t work within the PowerShell ISE. When you determine the property identify and ResultType, you may drill all the way down to that property.
The fields reveal the enum values. You may have some enjoyable with this.
Get-TypeMember serviceprocess.servicecontroller -MemberType Property | The place IsEnum | Foreach { Get-TypeMember $_.PropertyType -membertype subject}
I have already got a couple of enhancements in thoughts, however I’d love to listen to what you suppose.