Difference between revisions of "Functions"
From MyWiki
Line 3: | Line 3: | ||
\{<br> | \{<br> | ||
dir $dir |<br> | dir $dir |<br> | ||
− | where \{$_.length -gt $minsize | + | where \{$_.length -gt $minsize<br>\} |
\}<br><br> | \}<br><br> | ||
Is called like this:<br> | Is called like this:<br> | ||
FileSize3 -dir C:\Windows ` ( The back tick continues on a new line ) <br> | FileSize3 -dir C:\Windows ` ( The back tick continues on a new line ) <br> | ||
-minSize 100000 <br> | -minSize 100000 <br> |
Revision as of 19:25, 26 August 2014
http://windowsitpro.com/windows/create-your-own-powershell-functions
function FileSize3 ($dir, $minSize)
\{
dir $dir |
where \{$_.length -gt $minsize
\}
\}
Is called like this:
FileSize3 -dir C:\Windows ` ( The back tick continues on a new line )
-minSize 100000