简体   繁体   中英

GeckoFX does not work on visual studio 2013

i use GeckoFX 22 and xulrunner 22. \\After set a GeckoWebBrowser to a Winform program, a lot of work of my program done well, but when i set set a GeckoNode, it did not work, VS2013 throw an Exception with note:

" An exception of type 'System.NullReferenceException' occurred in Fifa17.exe but was not handled in user code Additional information: Object reference not set to an instance of an object. "

my code in that VS2013 throw an Exception is like that:

    GeckoNode gncMatchEvents = myBrowser.Document.GetElementById("content").ChildNodes[0];

The mistery is that: if i do not set a GeckoNode, another compose of GeckoFX still work like that:

    textBox1.Text = myBrowser.Document.GetElementById("content").ChildNodes[0].Length.ToString();

It's reaaly difficult to understand for me, thank for the answer.

i could repair the problem. There no any thing wrong in my code, but when i changed the version of GeckoFx and Xulrunner, everything run smoothly. I changed to GeckoFx29 and Xulrunner29 and running on street. But if i use GeckoFx14 and Xulrunner14, it's also run well. I was crazy in a week because that hell.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM