Comments (7)
Having the same problem here. I'm getting this error using multiple and single
threads.
"Unable to cast COM object of type 'System.__ComObject' to interface type
'Skybound.Gecko.nsIWebNavigation'." at run time. Mine fails on the line:
wbInfo.Navigate("http://www.google.com");
Where wbInfo is my GeckoWebBrowser object.
Original comment by [email protected]
on 14 Feb 2009 at 7:07
from geckofx.
Unable to cast COM object of type 'System.__ComObject' to interface type
'Skybound.Gecko.nsIWebNavigation'. This operation failed because the
QueryInterface
call on the COM component for the interface with IID
'{F5D9E7B0-D930-11D3-B057-00A024FFC08C}' failed due to the following error: No
such
interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE)).
Same problem here.
Note: Using the browser in a tab.
Original comment by [email protected]
on 16 Mar 2009 at 8:56
from geckofx.
The same...
Original comment by [email protected]
on 19 Jan 2010 at 2:52
from geckofx.
This error is thrown when you're trying to access the GeckoFX browser from a new
non-UI thread. Code sample that works:
void AsyncNavigate(string url) {
ThreadStart starter = delegate { AsyncNavigateThread(url); };
Thread thread = new Thread(starter);
thread.IsBackground = true;
thread.Start();
}
private delegate void StringDelegate(string url);
private void AsyncNavigateThread(string url) {
if (this == null || this.IsDisposed) return;
if (this.InvokeRequired || webBrowser.InvokeRequired) {
this.BeginInvoke(new StringDelegate(AsyncNavigateThread), new object[] { url });
return;
}
webBrowser.Navigate(url);
}
We need a better exception message though!
Original comment by [email protected]
on 19 Jan 2010 at 3:57
from geckofx.
I am trying to use GeckoFX because the standard WebBrowser control struggles
handling javascript in a number of areas. My implementation with WebBrowser
control runs in a ApartmentState.STA thread that has no UI. I have been unable
to get GeckFX to work in this scenario. I get an error stating that I cannot
navigate before the window handle is created and if I call CreateControl() on
th GeckoFX browser control, I get an object is null exception from the naviagte
call. The delegate code above is incomplete, so I wonder if you could post a
more complete answer.
Alos, might the right answer be to write a version of GeckoFX that does not
inherit from Control.
Any thoughts would be appreciated.
Original comment by [email protected]
on 18 Oct 2010 at 4:10
from geckofx.
Hey all...I am using the GeckoWebBrowser 1.9.1.0 in a .NET 2.0 application with
the XURLrunner 1.9.2.12 and have the same problem when executing this line of
code: webBrowser.Document.ActiveElement;
Unable to cast COM object of type 'System.__ComObject' to interface type
'Skybound.Gecko.nsIDOMNSDocument'. This operation failed because the
QueryInterface call on the COM component for the interface with IID
'{533A8131-8D0C-4EBF-990B-7FAD7CD514EE}' failed due to the following error: No
such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE)).
Nothing works...
--> I tried to use the AsyncNavigate hint
--> I tried to use the GeckoWebBrowser outside of a TabControl within a new
Form()
Everything I want to get work is to move the focus to the flash content when
the DocumentCompleted event raised. Does someone have an idea how to solve this
problem? I am happy for every hint.
Original comment by [email protected]
on 22 Nov 2010 at 8:44
from geckofx.
Hello,all:
My code is as follows:
private void button1_Click(object sender, EventArgs e)
{
Browser.Navigate("http://www.baidu.com");
GeckoElement script = Browser.Document.CreateElement("script");
script.SetAttribute("type", "text/javascript");
string str = "alert('ptmind');";
script.TextContent = str;
Browser.Document.Body.AppendChild(script);
}
while running GeckoElement script =
Browser.Document.CreateElement("script"),appear a error message as follow:
Unable to cast COM object of type 'System.__ComObject' to interface type
'Skybound.Gecko.nsIDOMNSDocument'. This operation failed because the
QueryInterface call on the COM component for the interface with IID
'{533A8131-8D0C-4EBF-990B-7FAD7CD514EE}' failed due to the following error: No
such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE)).
Regards
[email protected]
Original comment by [email protected]
on 11 Jan 2011 at 9:46
from geckofx.
Related Issues (20)
- Dll not compatable
- P/invoke Exception
- Facebook, HTML effects, etc.. dont work at all HOT 1
- Forum Admin And Mods Are Stupid HOT 1
- cant get xulrunner 7.0.1 to work with geckofx 1.9.1 ?
- Proxy
- Can't calll any javascript methods
- Does it support to drag drop event?
- how to manipulate document text
- document_completed eventhandle run 2 times HOT 1
- is inaccessible due to its protection level
- how to use geckofx in xaml ??
- Multiple Instances not working independently
- Popup window not working and Append new Addon Extentions.
- cannot naviaget to a intranet web page
- An unhandled exception of type 'System.InvalidCastException' occurred in Skybound.Gecko.dll
- Click even???
- Error: xulrunnerCall Xpcom.Initialize() in your application startup code and specify the directory where XULRunner is installed.
- Cannot navigate to urls. Timed out error
- Auto Download File from mozilla using geckofx HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from geckofx.