howto open a file excel 2002 with c# and office 2007 libraries?

S

spile

Hi,
when i try to print through c# and Office 2007 library
"Microsoft.Office.Interop.Excel" a xls created with an older version of
program (for example excel 2002-2003), the system raise the following error:
{"Old format or invalid type library. (Exception from HRESULT: 0x80028018
(TYPE_E_INVDATAREAD))"}

Can i reference more libraries that have the same namespace name?
or How can to do it?

thks
Maximo
 
B

Bob Buckland ?:-\)

Hi Maximo,

You may want to also post this question through the link below in the Excel Programming discussion group.

==========
Hi,
when i try to print through c# and Office 2007 library
"Microsoft.Office.Interop.Excel" a xls created with an older version of
program (for example excel 2002-2003), the system raise the following error:
{"Old format or invalid type library. (Exception from HRESULT: 0x80028018
(TYPE_E_INVDATAREAD))"}

Can i reference more libraries that have the same namespace name?
or How can to do it?>>
--
Please let us know if this has helped,

Bob Buckland ?:)
MS Office System Products MVP

LINKS
A. Specific newsgroup/discussion group mentioned in this message:
news://msnews.microsoft.com/microsoft.public.excel.programming
or via browser:
http://microsoft.com/communities/newsgroups/en-us/?dg=microsoft.public.excel.programming

B. MS Office Community discussion/newsgroups via Web Browser
http://microsoft.com/office/community/en-us/default.mspx
or
Microsoft hosted newsgroups via Outlook Express/newsreader
news://msnews.microsoft.com



thks
Maximo
 
J

johansonkatherine

Hi,
when i try to print through c# and Office 2007 library
"Microsoft.Office.Interop.Excel" a xls created with an older version of
program (for example excel 2002-2003), the system raise the following error:
{"Old format or invalid type library. (Exception from HRESULT: 0x80028018
(TYPE_E_INVDATAREAD))"}

Can i reference more libraries that have the same namespace name?
or How can to do it?

thks
Maximo


I would recommend you to try Aspose.Cells for .NET Library for opening excel files in c#. You can get sample codes from their documentation page and many more code sample that you can use in your API. Below is the link of this library. Best of luck.

http://www.aspose.com/.net/excel-component.aspx
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top