Empty excel file

Hello I import data from excel using workbook.Worksheets[0.ExportDataTable, now the problem is with the empty excel files, could please tell me how can i test if the file to import from excel is empty or not, i''d like to prevent choosing empty files. Thanks in advance,

1 Reply

AD Administrator Syncfusion Team May 15, 2006 10:51 AM UTC

Hi, Sorry for the delay in getting you. Please use the code below to detect whether a sheet contains data. sheet.UsedRange.IsBlank==true Please take a look at the attachment and let me know if you have any questions. EmptyDetector.zip BestRegards, Bharath

Loader.
Up arrow icon