Also called Automatic Variables.
Get-help about_automatic_variable
Search This Blog
Showing posts with label predefined constants. Show all posts
Showing posts with label predefined constants. Show all posts
Oct 26, 2011
Apr 20, 2011
Using System Namespace In Powershell
There are many cool pre-defined constants, functions, methods, and etc. in System object. One would normally learn individual ones through sample scripts, but really should browse the MSDN page to explore what System namespace has to offer. Go to a class/structure/enumeration that you are interested, then pay special attention to those static members.
A few examples:
[System.DateTime]::Today versus [System.DateTime]::Now
[System.String]::Empty
[System.Console]:: almost everything are static, not surprisingly
[System.Math]::PI
There are also a bunch of other namespaces, please see .Net Framework Libraries
A few examples:
[System.DateTime]::Today versus [System.DateTime]::Now
[System.String]::Empty
[System.Console]:: almost everything are static, not surprisingly
[System.Math]::PI
There are also a bunch of other namespaces, please see .Net Framework Libraries
Subscribe to:
Posts (Atom)