In my asp.net, C# application we are generating and downloading .xls file. But when I\'m trying to open, it\'s giving a message
\"The file you are try
Not sure how you are exporting data to excel. Setting the DisplayAlerts to false might help.
xlApp = new Excel.Application();
xlApp.DisplayAlerts = false;
I use interop DLL. The namespace would be Microsoft.Office.Interop.Excel
.
See Feng Chen's answer in the following link on how to add the reference: http://social.msdn.microsoft.com/Forums/en/netfxsetup/thread/c9e83756-4ae2-4ed4-b154-1537f3bb3a22
The following link might also help:
http://www.dotnetperls.com/excel