Why does Office 2010 fail to open an Excel file?

6

2

I have a excel file I've put on a file server. When required i access it via a dll, fill it with some data in background only (through ExecuteExcel functionality).

It used to work before. Recently I changed 2003 office to 2010 office version. After that it started throwing below error.

System.Runtime.InteropServices.COMException (0x80070BBC): Office has detected a problem with this file. To help protect your computer this file cannot be opened.

Even now also it works sometimes, and sometime throws above error.

What is the problem here?

niveiwish

Posted 2012-10-26T11:51:28.563

Reputation: 61

Can you please [edit] this question and give us more detail? What version of Excel, what type of server, how is the file being executed, etc? – CharlieRB – 2012-10-26T12:01:43.730

@CharlieRB:I have editted my answer.Please ask me if yu don`t understand. – niveiwish – 2012-10-26T12:09:29.110

Answers

3

Office 2010 file validation requires files or file locations to be trusted. Here is a knowledge base article about it - Error message in Microsoft Office 2010: "Office has detected a problem with this file".

Try adding the location of the file to trusted locations in File > Options > Trust Center > Trust Center Settings > Trusted Locations

Add, remove, or modify a trusted location for your files.

CharlieRB

Posted 2012-10-26T11:51:28.563

Reputation: 21 303

Charlie:I went through this article.I have given a trusted location to where i copy files.But still same problem. – niveiwish – 2012-10-26T12:56:11.270

Although I wasn't accessing the files in the same manner as you, I had the same problem when we upgraded to 2010 and this is how we fixed it. Have you installed all Windows & Office updates and restarted your computer? Do you still get the error with a local (on your hard drive, not on the network) copy of the file. – CharlieRB – 2012-10-26T13:52:51.610

:Yeah i restarted system.Updated office and windows.I got to know that its failing to get cellnames of hidden columns.I dont know why it`s failing.You have any suggestions???? – niveiwish – 2012-10-29T09:51:15.833

0

I have got the same trouble in Office 2013. My ASPX application is through Excell Interop trying to open XLS file. But fails. Problem occurs when the file is somehow identified as dangerous and Excell try open it in "safe mode". (could be for old XLS file, macros etc.) But method Excell.Workbooks.Open need exclusive access insted of "safe mode". So an error COMException (0x80070BBC) is invoked.

Solution: For me helped finaly this: 1) Change Excell setting according security (macros, etc.) under selected user (with local administrator rights). 2) A new application pool was created in IIS and set for the APSX application 3) The application pool Identity was changed to the user from step 1) 4) Restart IIS

user729893

Posted 2012-10-26T11:51:28.563

Reputation: 1