This project has moved. For the latest updates, please go here.

Load rows containing data

Oct 13, 2011 at 2:48 PM

Hi!

How can i determine the number of rows actually containing data in a worksheet loaded from the file. 

My problem i when I load a worksheet i get rowcount=1048576 that is true that is the upper limit but in my case im just interested in reading the rows that contain values. 

Is there a way to determine the used range ?

 

Best regards Anders

Coordinator
Oct 13, 2011 at 6:01 PM

In your case you'll probably be okay with other of the following:

ws.RangeUsed();

ws.LastRowUsed();


I could have sworn there was a worksheet.RowsUsed() method. I'll add it then.