473,322 Members | 1,522 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

QueryInterface for interface Excel._Application failed

The company I work for still uses Excel97. In a weaker moment I added the pia for Excel2003 in attempt to get more programatic functionality out of some Excel interfaces I have been writing. The pia is entitled 'Microsoft.Office.Interop.Excel.dll' I also added the registry entries for that pia by running 'Microsoft.Office.Interop.Excel.dll.reg.' After performing that stunt the following code consistantly fails on the second line

excelApp = new Excel.ApplicationClass()
excelApp.Visible = true

I can declare the new 'Excel.ApplicationClass(). Unfortunately every time I run 'excelApp.Visible = true' my program fails with the error

'QueryInterface for interface Excel._Application failed.

I have since manually removed 'Microsoft.Office.Interop.excel.dll.' The automatic removal of that pia failed. I have painstakingly removed the registry entries for the same. Can anyone explain what it is that I have failed to remove? Is it possible that I need to add something back into the registry for the Excel97.dll to run properly? If so what is that something. Thank you for any assistance you may be able to provide.

---
Posted using Wimdows.net Newsgroups - http://www.wimdows.net/newsgroups/
Nov 18 '05 #1
1 2327
This article should help you get your Excel code working one way or another:
http://www.aspnetpro.com/NewsletterA...200309so_l.asp

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://Steve.Orr.net
"Michael Connerton" <connertm@-NOSPAM-squared.com> wrote in message
news:eQ**************@TK2MSFTNGP12.phx.gbl...
The company I work for still uses Excel97. In a weaker moment I added the pia for Excel2003 in attempt to get more programatic functionality out of
some Excel interfaces I have been writing. The pia is entitled
'Microsoft.Office.Interop.Excel.dll' I also added the registry entries for
that pia by running 'Microsoft.Office.Interop.Excel.dll.reg.' After
performing that stunt the following code consistantly fails on the second
line:
excelApp = new Excel.ApplicationClass();
excelApp.Visible = true;

I can declare the new 'Excel.ApplicationClass(). Unfortunately every time I run 'excelApp.Visible = true' my program fails with the error:
'QueryInterface for interface Excel._Application failed.'

I have since manually removed 'Microsoft.Office.Interop.excel.dll.' The automatic removal of that pia failed. I have painstakingly removed the
registry entries for the same. Can anyone explain what it is that I have
failed to remove? Is it possible that I need to add something back into the
registry for the Excel97.dll to run properly? If so what is that something.
Thank you for any assistance you may be able to provide.
---
Posted using Wimdows.net Newsgroups - http://www.wimdows.net/newsgroups/

Nov 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Jason | last post by:
I'm writing a small console app in .NET that needs to reference a 3rd party dll. I wrote the app by adding a reference to the 3rd party dll in my project and my code builds and executes...
1
by: KC | last post by:
Hi Gurus, I am having problem opening an excel file from vb.net. My code looks like this: Dim EXL as Excel.Application Dim wrkbook As Excel.Workbook EXL = GetObject("", "Excel.Application")...
0
by: Deeps | last post by:
Hi I have created an interface called IGlobal with some properties exposed with a fixed Guid. Created a class inherting this interface. This is my com+ server. I have a client instantiating this...
4
by: Ram | last post by:
I am running a test web site on my own Win2k professional computer. I have a VB6 COM component (running on COM+) on a seperate application runnint as "Server". When running an ASP.NET page calling...
2
by: Dominique MILLOT | last post by:
Hello, With Asp.Net, I try to generat a document with an Excel object. This is the begin of my procedure: Dim xapExcel As Excel.Application xapExcel = New Excel.Application()...
1
by: Ugo | last post by:
Hi, I have just followed the Microsoft Knowledge Base Article - 302084 How to Automate Microsoft Excel from Microsoft Visual C# .Net http://support.microsoft.com/default.aspx?kbid=302084 and I...
1
by: adiel_g | last post by:
Hello, I have created a activeX dll in vb6 that contains some functions I am using in .NET. I created the dll in vb6 with: Instancing = 5-Multiuse MTSTransactionMode = 2-RequiresTransaction...
1
by: Joseph | last post by:
I have been using "XMLHTTPClass" in an asp.net module. It is properly referenced and was working up until recently. Now it is failing with the error message "QueryInterface for interface...
2
by: Stan | last post by:
Hello All: Don;t know if this is the correct group to post this in but here goes. Getting this error when trying to create excel object using Outlook Web Components on our web server. Any help...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.