• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 936
  • Last Modified:

Why is webbrowser object Url always null?

In .NET 3.5 winforms, I step through with the debugger and assign a webbrowser object's Url property.  After assigning, the property is still null.  I also tried this test:

            WebBrowser w = new WebBrowser();
            w.Url = url;

where url is a valid Uri.  Any suggestions on what I'm doing wrong?
0
brettr
Asked:
brettr
1 Solution
 
oobaylyCommented:
The Url property will remain null until the DocumentCompleted event has been raised.

Have a look at the Notes section under Remarks:
http://msdn.microsoft.com/en-us/library/system.windows.forms.webbrowser.url.aspx
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now