Excel 2007 error: Different format than specified by the file extension

After upgrading to Excel 2007, you may get the following error when you try to open an excel document:
The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted and is from trusted source before opening the file. Do you want to open the file now?

This errors particularly occurs when you’re trying to open an XLS file (Excel 2000-2003) with Excel 2007.

The easiest way to solve this problem, is to insert the following registry key. This will suppress the notification:

[HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\Excel\Security]
“ExtensionHardening”=dword:00000000

The step-by-step instructions are as follows:

  1. Click Start, click Run, type regedit.exe and press ENTER. This will open your Registry
  2. Navigate to HKEY_CURRENT_USER\SOFTWARE\MICROSOFT\OFFICE\12.0\EXCEL\SECURITY
  3. Right click in the right window and choose New -> DWORD
  4. In the Name field, type “ExtensionHardening”  (without the quotes)
  5. Verify that the data has the value “0”

I advice the steps above to solve the problem, despite the fact that it is quick and dirty.

If you want a more constructive way, you should define MIME types and associate them with extensions.
When you use a Document Management System (like Sharepoint or Livelink), you can try adding these:
.xls = application/msexcel
.xlsx = application/vnd.openxmlformats-officedocument.spreadsheetml.sheet

Leave a Reply

120 Comments on "Excel 2007 error: Different format than specified by the file extension"

Notify of
avatar
Sort by:   newest | oldest | most voted
mahender Singh
Guest

FILE OPEN IN THIS FORMAT ( I HAVE SAME PROBLEM IN EXCEL AND WORD)

c+B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B!„B

Please advise how can i Open my file.

Any software or translator or any other way to change the extention to open and recover my data.

Please reply.
Thank.

Vinod K. Chauhan
Guest
Accidentaly i delete my partitions and i use some partions recovery like minitool,partion magic 9.0 and get partitions and data back. but when i create new partiton usind partition magic9.0 suddenly current gone when i started pc again all partitions and data available but one partions nothing open my Photo,songs,videos, word file excel file what i do Plese suggest i need only Phosts and word excel file when i open excel file erreor msg is “The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted… Read more »
imgur
Guest

It means that you get total discounts at the time of subscription. Dream – Host is an online hosting company that offers products like domain registration, shared website hosting, Virtual Private
Server (VPS), and public cloud services. You can be diligent about protecting your website but someone else on the same server
might not be.

Pavani
Guest

I an trying to save the excel file through jsp. i gave below piece of code in my jsp

response.setHeader(“Content-disposition”, “inline;filename=FMI_GlobalSummary.xlsx”);

file saved but while a am trying to open that excel file it is giving the error The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted and is from trusted source before opening the file. Do you want to open the file now?

Please help me here- need it urgently

toine
Guest

How can you set it up for all users?

Anonymous
Guest
Use a Group Policy setting Download the 2007 Office system Administrative Template files (ADM, ADMX, ADML) and Office Customization Tool from the following Microsoft Download Center Web site: http://www.microsoft.com/downloads/thankyou.aspx?familyId=92d8519a-e143-4aee-8f7a-e4bbaeba13e7 Extract the administrative template files to a folder. To do this, follow these steps: Double-click the AdminTemplates.exe file. Accept the Microsoft Software License Terms, and then click Continue. Select a folder in which to save the extracted files, and then click OK. Click OK after the files have been extracted successfully. Open the Group Policy Object Editor. For more information about how to open the Group Policy Object Editor, visit the… Read more »
Rashid iqbal
Guest

Nice work, thanks for giving this solution.

Karu Karthi
Guest

Hi
I am working in sharepoint 2013 , exporting excel of rdlc file rendering problem..opening in PDF s working fine..after exporting into excel and trying to open the excel i am not getting the exact content..

Mens Indowestern
Guest

I hope you write more on this subject! Wow, that was pretty interesting. Inspiring, as well. Thanks for sharing such inspiring experience with us. Great blog, congrats! I found lots of interesting information here. The post was professionally written and I feel like the author has extensive knowledge in this subject.

Anonymous
Guest

awesome

Krishna
Guest

It working in the server machine. the error getting in client machine.

Urdu Shayari
Guest

This is good information thanks for share

Hemanth kumar D
Guest

Hi,

Your solution really worked. Its an excellent trick.

Thanks,

Hemanth

Hemanth kumar D
Guest

Excellent trick to avoid warning..Thanks alot

mustafa
Guest

excellent trick

raja
Guest

Not Working………… Can Anyone Help needed Urgent………….

jayesh
Guest

what a solution dear
nice
selut

Anuradha
Guest

Excellent solution..

ayz
Guest

i already get rid the msg box but still it is on special characters. pls help

ArunKumar
Guest

Super Solutions.
its Working Perfectly..

Anonymous
Guest

Excellent solution..

Super Solutions.
its Working Perfectly..

shrikant
Guest

Excellent Solution

shrikant
Guest

Excellent Reply

Srinivas
Guest

Excellent, it is worked for me.

Sangeetha
Guest

Hi,

Good solution.Its worked Properly.Thank you.

mUEKSH
Guest

Hi I tried adding HKEY_CURRENT_USER\SOFTWARE\MICROSOFT\OFFICE\12.0\EXCEL\SECURITY
but my excel documents are still corupt. any help please

srilatha M
Guest

Thank you,It was worked for me

Santos
Guest

It did work for me. However I did add it under 14.0 instead of 12.0
HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Excel\Security]

Cheers

riki
Guest

IT WORKED FOR BY CHOOSE THIS ONE . than”s

It did work for me. However I did add it under 14.0 instead of 12.0
HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Excel\Security]

Cheers

Anonymous
Guest

It did work for me. However I did add it under 14.0 instead of 12.0
HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Excel\Security]

Cheers

Kajal
Guest
Hey hii I an trying to save the excel file through jsp. file saved but whikle a am trying to open that excel file it is giving the error The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted and is from trusted source before opening the file. Do you want to open the file now? i am workin in excel 2007,i do all changes in 12.0 but still not working,there is no 14.0,there is only 8.0 other than 12.0,but in that 8.0 there is… Read more »
Anonymous
Guest
Need Help!! i am looking for solution which give, eport in xlsx (2007)format in Jsp. i tried all possible ways you mentioned, but its not working.. Is there any other way, to overcome to this problem Hey hii I an trying to save the excel file through jsp. file saved but whikle a am trying to open that excel file it is giving the error The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted and is from trusted source before opening the file. Do… Read more »
Steven
Guest

Solution Works Perfectly.
Thanks Christian!

charisse
Guest

hi.. what you gave worked. it just remove the message box. My problem is when i always open it, with or without the “extensionHardening”, it doesn’t show anything.. what should i do?

Melly
Guest

I get to the registry part fine, but I do not have the SECURITY part. Is there another spot I could put it? Thanks!

Sundas
Guest

I was working on office 2007 file. Then my pc became turned off due to electricity problem. After this, when i turn on my pc i have lost my excel file. An xls file is appeared instead. when i tries to open it then says, “The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted and is from trusted source before opening the file. Do you want to open the file now?”
Please Please Please Help Me its my job’s problem.

Deepti
Guest

For people who are getting junk characters they can try removing Response.ClearHeaders(). This gives error with IIS 6

Anonymous
Guest

For people who are getting junk characters they can try removing Response.ClearHeaders(). This gives error with IIS 6

How do you remove Response.ClearHeaders()

Anonymous
Guest

Need Help!!
i am looking for solution which give, eport in xlsx (2007)format in Jsp.
i tried all possible ways you mentioned, but its not working..
Is there any other way, to overcome to this problem

Mahesh
Guest
Accidentaly i delete my partitions and i use some partions recovery like minitool,partion magic 9.0 and get partitions and data back. but when i create new partiton usind partition magic9.0 suddenly current gone when i started pc again all partitions and data available but one partions nothing open my Photo,songs,videos, word file excel file what i do Plese suggest i need only Phosts and word excel file when i open excel file erreor msg is “The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted… Read more »
Anonymous
Guest
Accidentaly i delete my partitions and i use some partions recovery like minitool,partion magic 9.0 and get partitions and data back. but when i create new partiton usind partition magic9.0 suddenly current gone when i started pc again all partitions and data available but one partions nothing open my Photo,songs,videos, word file excel file what i do Plese suggest i need only Phosts and word excel file when i open excel file erreor msg is “The file you are trying to open .xlsx is in a different format than specified by the file extension. verify the file is not corrupted… Read more »
frankreid
Guest

Thanks, This solved the problem.

Anonymous
Guest

Worked for me… :)

HM
Guest

Given registry modification solution worked for me. Thanks

sulekha
Guest

The file you are trying to open .xls is in a different format than specified by the file extension. verify the file is not corrupted and is from trusted source before opening the file.

I am getting while try to open a EXL 2003 file in 2007.Is there any other way to reslove this prob except registry change or group change policy

Anonymous
Guest

The file you are trying to open .xls is in a different format than specified by the file extension. verify the file is not corrupted and is from trusted source before opening the file.

I am getting while try to open a EXL 2003 file in 2007.Is there any other way to reslove this prob except registry change or group change policy

omar
Guest

Excellent

Muhammad Javed
Guest

hFÿÿÿÿ@À{°FØÿÿÿÿ@X|p|˜| ”•0…°Fÿÿÿÿ@X|øFÐÿÿÿÿ@è|} }0–0…øFÿÿÿÿ@è|0GÈÿÿÿÿ@p}ˆ}¨}—0…0Gÿÿÿÿ@p}hG¸ÿÿÿÿ@ø}~P~ ™x™°„(¦P™„hGÿÿÿÿ@ø}°Gxÿÿÿÿ@H Hÿÿÿÿ@È~à~¸ž œè›À›˜›°Gpÿÿÿÿ@H¨œÀp°Gÿÿÿÿ@H Hÿÿÿÿ@È~ÐHÿÿÿÿ@€ €àH€ Ÿ0…¨Hÿÿÿÿ@p€ˆ€H€ Ÿ0…êPÿÿÿÿ@ †`RPÿÿÿÿ@H xI

Dear all,
i did with registry file as you told you above but excel file is still showing the same issue actually i
had recover that excel data and know it is not opened
i got this error message when try to open it

the file you are trying to open,name.xls is in a different format then specified by the file extension. verify that file is not corrupted and is from
a trusted source before open the file do you want to open the file now ?

some one can please tell me the solution

Gunter
Guest

That was excellent, “ExtensionHardening“
it worked like a Spell

thanks

Anonymous
Guest

That was excellent, “ExtensionHardening“
it worked like a Spell

thanks

Aslam
Guest

Hi,

While opening the file we receives the content which was low level format example ” ªdÕ /1éƒO@üôâVR-D«›°‰)¿:5Ë«±Ï!œn¶h%P¹Þ.Þy¼äÞXÎàš43€x©õJÉ<ÁHl-&ð´æ)Tm á ‘Gí€=mm`„µ„ þ "….
ªdÕ /1éƒO@üôâVR-D«›°‰)¿:5Ë«±Ï!œn¶h%€P(Þ.Þy¼äÞXÎàš†Ê‡¨õJÉ<ÁHl-&~´æ)¹m á<n¸<6~Â’wýŸ{,yß+ØoåSPp:HFÝKygÆ­

any other way to open the file

nk
Guest

Hi,

Is there any other alternative rather than changing the registry?

Sam
Guest

sorry, file open but not in correct formatt

AMJ
Guest

Lovely…… I got rid of the annoying message-box :-)

Ali Ahamad
Guest

Sir,

While opening the file we receives the content which was low level format example ” ªdÕ /1éƒO@üôâVR-D«›°‰)¿:5Ë«±Ï!œn¶h%P¹Þ.Þy¼äÞXÎàš43€x©õJÉ<ÁHl-&ð´æ)Tm á ‘Gí€=mm`„µ„ þ "….

please suggest in this regard.

Thanks, Ali.

Anonymous
Guest

Sir,

While opening the file we receives the content which was low level format example ” ªdÕ /1éƒO@üôâVR-D«›°‰)¿:5Ë«±Ï!œn¶h%P¹Þ.Þy¼äÞXÎàš43€x©õJÉ<ÁHl-&ð´æ)Tm á ‘Gí€=mm`„µ„ þ “….

please suggest in this regard.

Thanks, Ali.

jambai
Guest

It works good.

Would lke to know is there any other alternative rather than changing the registry or group policy.

Thanks
Jambai

Sachin
Guest

Hi, Thanks for the post. Your solution worked!

Nikita
Guest

I was gettibg the same error, the regedit jhelps to erase the error but still the data is incorrect. It gives some corrupt junk data.
Can u help please?

Gamecock
Guest

Great fix! Thank you so much!

Mike
Guest

I love you.

Sherri
Guest

I’m having this issue with a file when I open it. Your solution looks good, but won’t it only work on my laptop? What can I do if my file is going to be opened by others on different computers?

younes
Guest

I’m having this issue with a file when I open it. Your solution looks good, but won’t it only work on my laptop? What can I do if my file is going to be opened by others on different computers?

that would be their problem and not yours.

wpDiscuz