I am trying to get the character count for each row in a text doc. The contents of my text doc are:
1
15
69
124
300
I've been trying variants of the PS script:
get-content c:\serverlist.txt | foreach-object {measure-object -character}
But the best I can get returned is:
Lines Words Characters Property
------- -------- -------------- -----------
0
0
0
0
0
Not sure what I'm missing here, but any help would be appreciated!
Thanks!