Cannot fetch data when provding range such as B9:T

Hi,

I am facing a issue in xlsIO while reading data from excel when providing range as B9:T it give below error:-

System.ArgumentException: name cannot be less then 2 symbols
   at Syncfusion.XlsIO.Implementation.RangeImpl.CellNameToIndex(String name)
   at Syncfusion.XlsIO.Implementation.RangeImpl.ParseRangeString(String range, IWorkbook book, Int32& iFirstRow, Int32& iFirstColumn, Int32& iLastRow, Int32& iLastColumn)
   at Syncfusion.XlsIO.Implementation.RangeImpl.get_Item(String name, Boolean IsR1C1Notation)

But when I was processing other file with same range type but with A3:DH it works.

I found a workaround by adding worksheet.UsedRange.LastRow to the range but, this might be a issue .

2 Replies

SK Shamini Kiruba Sobers Syncfusion Team December 9, 2020 01:05 PM UTC

Hi Amey, 

Greetings from Syncfusion support. 

We are able to reproduce the reported issue and validating it currently. We will share the validation details on December 11th, 2020

Regards, 
Shamini 



SK Shamini Kiruba Sobers Syncfusion Team December 11, 2020 02:47 PM UTC

Hi Amey, 

We need to provide two characters either row and column or column names with two character for getting the range in XlsIO. This is a behavior in XlsIO. So, we suggest to provide last row value. 
 
Regards, 
Shamini 


Loader.
Up arrow icon