TheSwamp

Code Red => .NET => Topic started by: sinc on March 12, 2010, 07:36:06 PM

Title: E_NOINTERFACE
Post by: sinc on March 12, 2010, 07:36:06 PM
Anyone know anything about this?

I have an application that gets this error when attempting to access the AcadApplication via the Interops.

Jeff found this link (http://techpunch.wordpress.com/2009/06/22/com-interop-queryinterface-not-supported-e-nointerface/), but I don't know if it has anything to do with it or not.  If this is the problem, why would I only see this error on only one computer?
Title: Re: E_NOINTERFACE
Post by: Bryco on March 15, 2010, 06:04:06 PM
Does vba have to be installed on a machine for interop to work?
Title: Re: E_NOINTERFACE
Post by: sinc on March 15, 2010, 07:30:41 PM
It's the other way around.  VBA requires the Interops, and can't use the .NET interface.  Or maybe I should say VBA and the Interops both use the COM interface, instead of the .NET interface.
Title: Re: E_NOINTERFACE
Post by: mjfarrell on March 15, 2010, 07:34:57 PM
can you post the code or the entire error to help in searching for possible other causes?  (there do seem to be a lot of reasons one could be gettin this error)
Title: Re: E_NOINTERFACE
Post by: Jeff_M on March 16, 2010, 02:22:09 AM
This is the error:
Quote
Unable to cast COM object of type ‘System.__ComObject' to interface type ‘Autodesk.AutoCAD.Interop.AcadApplication’. This operation failed because the QueryInterface call on the COM component for the interface with IID ‘{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}’ failed due to the following error: No such interface supported (Exception from HRESULT: 0×80004002 (E_NOINTERFACE)).
Title: Re: E_NOINTERFACE
Post by: Bryco on March 16, 2010, 09:45:00 AM
Since 2010 cad requires a separate download of vb I thought perhaps that machine didnt have it but it doesn't make much sense
Title: Re: E_NOINTERFACE
Post by: mjfarrell on March 16, 2010, 10:25:04 AM
try this http://through-the-interface.typepad.com/through_the_interface/2009/05/index.html (http://through-the-interface.typepad.com/through_the_interface/2009/05/index.html)


http://www.marcvalk.net/2009/08/microsoft-windows-7-64bit-and-ie8-new-tab-hang/ (http://www.marcvalk.net/2009/08/microsoft-windows-7-64bit-and-ie8-new-tab-hang/)
Title: Re: E_NOINTERFACE
Post by: sinc on March 16, 2010, 10:55:49 AM
I don't see anything in either of those links that seems to apply.

My current working theory (which may be completely bogus) is that it is caused by another Autodesk product being installed side-by-side with Civil 3D.  Unfortunately, the target machine has about 15 Autodesk products installed on it...   :laugh:
Title: Re: E_NOINTERFACE
Post by: mjfarrell on March 16, 2010, 11:07:45 AM
perhaps if all those XXXXXXX's were actual numbers; a search might yield more usefull information?


•Microsoft SQL Server Management Studio: An error with a message like “Unable to cast COM object of type ‘System.__ComObject’ to interface type ‘Microsoft.VisualStudio.OLE.Interop.IServiceProvider’. This operation failed because the QueryInterface call on the COM component for the interface with IID ‘{6D5140C1-7436-11CE-8034-00AA006009FA}’ failed due to the following error: No such interface supported (Exception from HRESULT: 0×80004002 (E_NOINTERFACE)). (Microsoft.VisualStudio.OLE.Interop)

I’m not sure of the exact details, but this is what I think I’ve found. Perhaps someone at Microsoft would correct or elaborate on this.

Previously, actxprxy.dll (ActiveX Interface Marshaling Library) was used as the proxy for a multitude of system interfaces, such as IShellFolder and IServiceProvider.

In Windows 7 (and probably Vista also), the GUID of this library has changed from {B8DA6310-E19B-11D0-933C-00A0C90DCAA9} to {C90250F3-4D7D-4991-9B69-A5C5BC1C2AE6}

Secondly, there is also a new Proxy/Stub provider found in ieproxy.dll of Internet Explorer (IE ActiveX Interface Marshaling Library). Some interfaces that previously used actxprxy.dll are now registered to use ieproxy.dll.

Now various problematic software (such as Vault 3.x) will try to register against actxproxy using the old GUID, and for interfaces now proxied by ieproxy.dll.
Title: Re: E_NOINTERFACE
Post by: LE3 on March 16, 2010, 11:29:26 AM
This is the error:
Quote
Unable to cast COM object of type ‘System.__ComObject' to interface type ‘Autodesk.AutoCAD.Interop.AcadApplication’. This operation failed because the QueryInterface call on the COM component for the interface with IID ‘{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}’ failed due to the following error: No such interface supported (Exception from HRESULT: 0×80004002 (E_NOINTERFACE)).


Is this happen after a windows update?... but still that error means that the com dll is not correctly registered on your system - try to re-register manually via regsvr32
Title: Re: E_NOINTERFACE
Post by: sinc on March 16, 2010, 11:41:23 AM
perhaps if all those XXXXXXX's were actual numbers; a search might yield more usefull information?

That was the very first thing I tried.  No hits.
Title: Re: E_NOINTERFACE
Post by: sinc on March 16, 2010, 11:42:38 AM
Is this happen after a windows update?... but still that error means that the com dll is not correctly registered on your system - try to re-register manually via regsvr32

Do you mean try repairing/reinstalling Civil 3D?  I would have no idea how to re-register the DLLs, except to do a "repair installation"...
Title: Re: E_NOINTERFACE
Post by: mjfarrell on March 16, 2010, 11:48:07 AM
the article I quoted from last had an example of how to manually register the particular DLL's their article found to be a solution to the issue (they were experiencing)   Perhaps that Batch file could be modified to suit

http://www.davidmoore.info/tag/c90250f3-4d7d-4991-9b69-a5c5bc1c2ae6/ (http://www.davidmoore.info/tag/c90250f3-4d7d-4991-9b69-a5c5bc1c2ae6/)
Title: Re: E_NOINTERFACE
Post by: LE3 on March 16, 2010, 11:58:32 AM
Is this happen after a windows update?... but still that error means that the com dll is not correctly registered on your system - try to re-register manually via regsvr32

Do you mean try repairing/reinstalling Civil 3D?  I would have no idea how to re-register the DLLs, except to do a "repair installation"...

I am not familiar with C3D.
I mean the dll in particular... you can copy regsvr32.exe (that it is under windows\system32 well at least on my winxp system) on the same location as the dll and use: regsvr32 theName.dll <enter>
or attached here is a tool for that (been using it for years). HTH
Title: Re: E_NOINTERFACE
Post by: sinc on March 16, 2010, 11:59:50 AM
The problem is that I have no idea IF that's the problem, or if it is, what the correct GUID should be for what key.

My current working theory is that it's something that happens when 64-bit and 32-bit Autocad products are installed side-by-side, but I have no idea how to fix it.
Title: Re: E_NOINTERFACE
Post by: sinc on March 16, 2010, 12:02:09 PM

I am not familiar with C3D.
I mean the dll in particular... you can copy regsvr32.exe (that it is under windows\system32 well at least on my winxp system) on the same location as the dll and use: regsvr32 theName.dll <enter>
or attached here is a tool for that (been using it for years). HTH


That still leaves the question as to which DLL to try to re-register.  I'm also leery of having the client start trying to re-register Autodesk DLLs at random, when I have no idea what I'm telling them to do or if it will help...  Can this cause anything to get messed up?
Title: Re: E_NOINTERFACE
Post by: LE3 on March 16, 2010, 12:07:16 PM
That still leaves the question as to which DLL to try to re-register.  I'm also leery of having the client start trying to re-register Autodesk DLLs at random, when I have no idea what I'm telling them to do or if it will help...  Can this cause anything to get messed up?

Not an expert in any way...
I have done several ATL/COM servers and got that error returned at least once - and was about a bad installation or a mess after a windows update.

Apart of that... do not know what to offer. :)
Title: Re: E_NOINTERFACE
Post by: sinc on March 16, 2010, 12:08:18 PM
Maybe the best thing is to just suggest a repair/reinstallation of Civil 3D.  The client is an Autodesk reseller, so he should be used to hearing that...   :lol:
Title: Re: E_NOINTERFACE
Post by: mjfarrell on March 16, 2010, 12:10:22 PM
sinc,
 I can't relocate the page where a user indicated removal of the explicit GUID # and hard paths from his project, and the issue was resolved...for them....now I could only find that link
Title: Re: E_NOINTERFACE
Post by: mjfarrell on March 16, 2010, 12:11:39 PM
Maybe the best thing is to just suggest a repair/reinstallation of Civil 3D.  The client is an Autodesk reseller, so he should be used to hearing that...   :lol:

Oh YEAH!  that's some sweet revenge there....
Just keep removing and reinstalling the application until it sorts itself out. :lmao:
Title: Re: E_NOINTERFACE
Post by: Jeff_M on March 16, 2010, 12:15:46 PM
Searching my registry for the specific IID yields a location in HKLM\Software\Classes\Interface. This has an entry for TypeLib which points to another key which has a reference to the acax18enu.tlb

Don't know how this helps, just saying that's what I have and the code works flawlessly for me.