I am trying to read the data from an excel sheet and put in a windows form in table view. While reading the data, I need to know any method where I don't have to give the end cell value manually, i.e. it should be able to reach the end of non-empty rows by itself. Also I want to know how to read all the columns for all the rows. I am attaching the file I am trying to read and export the data as it is in Windows Form DATA GRID.
A worksheet has a property named UsedRange. This will show you the boundaries of the data. You will need to get the worksheet first and then extract a proxy to access the UsedRange. I am going to add a post today that will show how to get a worksheet by name and then how to get the used range. Look for those posts.