Monthly Archives: March 2014

Powershell function to count files using Robocopy

Reading the post title you maybe wondering whether I’ve taken leave of my senses.  Why call Robocopy from Powershell to count files when Powershell has a perfectly good method of doing this natively? For example, (Get-ChildItem e:\powershell -Recurse -force | ?{! $_.PSIsContainer} | Measure-Object).count Well, the problem comes in when an individual file length exceeds 260… Read More »