Click here to Skip to main content
15,886,067 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

I have a Windows form which contains a WebBrowser control which is navigating to say for ex: www.google.com.

Now when I launch my application the following event occurs:
1. The windows form loads(blank)
2. after few seconds, the WebBrowser loads the intended page(here www.google.com)

Now my requirement is:
I want to display an Image(say: Loading image) before the webbrowser loads the page in the form.
So as soon as I launch the application, it should first display the Loading Image and the the Form with the Loaded web page inside it.

Can anybody help me here to achieve the same.

thanks,
Rajeev
Posted

Hide the WebBrowser control before you start to load (set Visible to False in the designer), and (for simplicity) put a PictureBox on your form.
Handle the WebBrowser DocumentCompleted event.
When the event fires, hide your PictureBox and display the WebBrowser.
 
Share this answer
 
check this[^] it may help you.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900