I am exporting a file in xlsx format after saving the file i am importing it back, but while importing it back I am getting External table is not in the expected format
exception. However when i am opening the imported file and just save it again it work like a charm and I am able to import it back
For Exporting
content type - application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
context.Response.WriteFile(filePath);
For Importing
Excel connection string - "Provider=Microsoft.ACE.OLEDB.12.0;Data Source={0};Extended Properties=" + (char)34 + "{1};HDR=Yes;IMEX=1" + (char)34 + ";";