[VBS] Count number of rows in text file
4 October, 2011 at 10:55 am Leave a comment
‘copied from internet
Note: No blank lines between lines
Set FSO = CreateObject(“Scripting.FileSystemObject”)
Set file = FSO.OpenTextFile(“C:\Documents and Settings\a5105628\Desktop\ITSR44952_aug11.txt”, 1)
file.ReadAll
‘subtract one ReadAll stops at the first blank line
msgbox (file.line)-1
Entry filed under: IT/Soft.
Trackback this post | Subscribe to the comments via RSS Feed