Exporting data to excel from datagrid, Problem.
How are you all? Hope you all are fine.
I have successfully downloaded data from datagrid to an excel file. Now I am trying to upload that excel file into the web-server after that I was trying to access that excel file as database. OK!
But an error occurred. The error message was “External table is not in the expected format.” Then I have checked the downloaded excel file’s format.
The downloaded excel file’s type was “Web page”. I also have checked its Response.ContentType, That was “text/html”.
But in my download code I have mentioned
Response.ContentType = "application/vnd.ms-excel";
Hope you all understand the problem.