This web site uses Kentico CMS, the content management system for ASP.NET developers.

Community > Blogs > Max-PIT> PowerShell Blog > November 2008
 

You can use the combination of "Get-member" with "Out-File" to help you get the list of Methods and Properties of your collection of .NET (or COM) objects from your $x variable.  In the following sample, you create a variable $x.  The purpose is to have another way to access the list of methods and properties so you won't open another PowerShell session in order to get to it.  I think this is a practical way to do it.  This way you can get the list from a notepad editor so you can see what's available. 


Sample Code

PS> $x = 'TEST'

PS> $x | gm | out-file -FilePath c:\temp\gm.txt ; ii c:\temp\gm.txt

 


Have fun!!
Max
Posted: 11/13/2008 11:09:08 AM by Global Administrator | with 0 comments


Thanks to Microsoft Buck Woody, during one of his virtual seesion, he provided a resource link were you can download a free PowerShell workbook:
<Free Windows PowerShell workbook: server administration>

Please, make sure to download the language version you want, there's English and German.


Enjoy,
Max
Posted: 11/8/2008 10:08:14 AM by Global Administrator | with 0 comments


This web site uses Kentico CMS, the content management system for ASP.NET developers.