Reputation: 2904
When I run this command:
$psise.CurrentPowerShellTab.AddOnsMenu.SubMenus | GM
The result does not show me the methods Remove
& Removeat
which I know do exist. So how do we discover all the methods available to an object?
I have run GM -force
but still don't see the Remove
methods. Are these methods being generated dynamically?
Upvotes: 0
Views: 39
Reputation: 22132
Collections are enumerated, when passed by pipeline. What you see by
$psise.CurrentPowerShellTab.AddOnsMenu.SubMenus | GM
is a members of SubMenus
collection's elements not collection itself. To get members of collection you need write it like this:
,$psise.CurrentPowerShellTab.AddOnsMenu.SubMenus | GM
or this:
GM -InputObject $psise.CurrentPowerShellTab.AddOnsMenu.SubMenus
Upvotes: 2