Free Support Forum - aspose.com

Unable to load .xls file to WebGrid

Hi Amjad,

I am trying to load excel file which consists of different controls ( text box, radio button etc) in it , but I fail everytime I try to load

string fileName = path + \\File\\Test.xls;

FileStream fs = File.OpenRead(fileName);

// Clears datasheets first.

GridWeb1.WebWorksheets.Clear();

// Imports from a excel file.

GridWeb1.WebWorksheets.ImportExcelFile(fs); // I get "Object reference not set to an instance of an object" error at this point , the file is present @ the path specified

Could you please help me out as I am unable to processed further ,

Thanks in advance

Warm Regards,

Aravind Kumar Anchalia

Hi,


Could you attach your “Test.xls” file here, we will check it soon.

Also, make sure that your are using latest version/fix, e.g v2.7.15.2002 (attached).

Thank you.