V
VBSome
As far as I understand there is no native VB.NET equivalent of the VB6 Web
browser control. There are some things I can play with HTML wise, but none
do what I really need to do (which is ultimately walk the DOM &
programatically click on elements in the DOM).
I am trying to rebuild some of the stuff I've done in VB6 in dotnet by using
the web browser control thru the com interop. HELP! It behaves different
then I am used to and I am not sure where to go from here...
One of the most important events in what I am trying to accomplish is the
DocumentComplete event. The DocumentComplete fires (or at least should fire)
every time a document in a frame or an iFrame is done loading in the web
browser.
For what I need to do (and I have this working perfectly in VB6) I need to
wait an X amount of docComplete events before continuing with the rest of
the code. In VB6 this is no problem. The method I write that navigates
simply looks at a property I declared that gets upped by one every time the
doComplete fires. VB6 is lovely in its stupidity that my method will
actually halt for as long as the property is not X (Do while).
This same logic does not work in dotnet. I have a navigate method and at the
class level I declare a withevents variable. If I put a Do... While
(encapsulating the check for the property value) in my navigate method, it
never releases and the docComplete event never fires. If I take the Do...
While out, then the doComplete fires but not until my navigate method is
already finished...
Obviously I am a dotnetnewbie.... What am I doing wrong??
browser control. There are some things I can play with HTML wise, but none
do what I really need to do (which is ultimately walk the DOM &
programatically click on elements in the DOM).
I am trying to rebuild some of the stuff I've done in VB6 in dotnet by using
the web browser control thru the com interop. HELP! It behaves different
then I am used to and I am not sure where to go from here...
One of the most important events in what I am trying to accomplish is the
DocumentComplete event. The DocumentComplete fires (or at least should fire)
every time a document in a frame or an iFrame is done loading in the web
browser.
For what I need to do (and I have this working perfectly in VB6) I need to
wait an X amount of docComplete events before continuing with the rest of
the code. In VB6 this is no problem. The method I write that navigates
simply looks at a property I declared that gets upped by one every time the
doComplete fires. VB6 is lovely in its stupidity that my method will
actually halt for as long as the property is not X (Do while).
This same logic does not work in dotnet. I have a navigate method and at the
class level I declare a withevents variable. If I put a Do... While
(encapsulating the check for the property value) in my navigate method, it
never releases and the docComplete event never fires. If I take the Do...
While out, then the doComplete fires but not until my navigate method is
already finished...
Obviously I am a dotnetnewbie.... What am I doing wrong??