johnrobert
-
Total Posts
:
5
- Scores: 0
-
Reward points
:
0
- Joined: 10/3/2011
-
Status: offline
|
name and row count of excel files in a directory
Monday, October 24, 2011 2:36 AM
( permalink)
I have a set of excel files in a directory, is it possible to print every file name and the number of rows in each file through a vb script? if yes, could some one please help me. ************** Com_Init() Loop, D:\Excel-tep\Efiles\*.xls { xlBook := Com_GetObject(A_LoopFileFullPath) xlRng := Com_Invoke(xlBook, "ActiveSheet.UsedRange") records := Com_Invoke(xlRng, "Rows[1].Row") + Com_Invoke(xlRng, "Rows.Count") - 1 t .= A_LoopFileName " (" records " Lines)`n" Com_Release(xlBook), Com_Release(xlRng) } Com_Term() ****************
|
|
|
|