Dear All,
I have dropped a WebBrowser control onto my form but It will not display the webpage I have set the code to navigate to. Snippet is - APBrowsePage.Navigate("http://www.microsoft.com"); .
Where APBrowsePage is the control name.
Zip your project and upload it. You can do this by clicking "Go Advanced" next to "Post Quick Reply", and in the next screen click on manage attachments.
Ramy,
I have already tried to convert the URL to URI but that doesnt work either. Scott - The project should be attached - not sure what you needed so I put everything in.
Ramy,
Theres no error - the control is just blank when I run the exe. Does the line of code need to defined in a particular event that I am not yet handling?
webBrowser1.Url = new Uri("http://microsoft.com");
}
That is in the document complete event but I don't see anywhere that initially tell the navigator to browse. You should not be changing the browser's URL in the complete event because when it finishes loading a page it will call that event, triggering another page load, and it will loop.
Dear All,
Thanks for your help - I've now got it working. I had been using the DocumentCompleted event because this was automatically created when I double clicked on the object.
No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.