Solved

WebBrowser control test Frame has loaded

Posted on 2009-05-10
3
544 Views
Last Modified: 2012-06-27
Hi Experts,

What is the best way to test a frame has loaded into a webbrowser control.

I am trying the code below but it gives a 'Object reference not set to an instance of an object.' error.
If WebBrowser1.Document.Window.Frames("leftFrame").Document Is Nothing Then
 
End If

Open in new window

0
Comment
Question by:DColin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 6

Assisted Solution

by:poweraddict
poweraddict earned 500 total points
ID: 24351379
See if this helps

http://www.experts-exchange.com/Programming/Languages/.NET/Visual_Basic.NET/Q_22515250.html


there is also a webbrowser1.isBusy property im pretty sure
0
 

Author Comment

by:DColin
ID: 24361553
poweraddict:

Thanks for the link but I need to know when a specific frame has loaded not when the whole page has finished loading.
0
 

Accepted Solution

by:
DColin earned 0 total points
ID: 24634207
Hi Experts,

Found answer.
Private Sub WebBrowser1_DocumentCompleted(ByVal sender As Object, ByVal e As System.Windows.Forms.WebBrowserDocumentCompletedEventArgs) Handles WebBrowser1.DocumentCompleted
 
        ListBox1.Items.Add(e.Url)
 
End Sub

Open in new window

0

Featured Post

Enroll in June's Course of the Month

June’s Course of the Month is now available! Experts Exchange’s Premium Members, Team Accounts, and Qualified Experts have access to a complimentary course each month as part of their membership—an extra way to sharpen your skills and increase training.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
There are cases when e.g. an IT administrator wants to have full access and view into selected mailboxes on Exchange server, directly from his own email account in Outlook or Outlook Web Access. This proves useful when for example administrator want…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question