This documentation is archived and is not being maintained.

WebBrowser.Refresh Method (WebBrowserRefreshOption)

Reloads the document currently displayed in the WebBrowser control using the specified refresh options.

Namespace:  System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

public void Refresh(
	WebBrowserRefreshOption opt

The WebBrowser control stores recently visited Web pages in a cache on the local hard disk. Each page can specify an expiration date indicating how long it will remain in the cache. When the control navigates to a page, it saves time by displaying a cached version, if one is available, rather than downloading the page again. The Refresh method forces the WebBrowser control to reload the current page. The type of reload depends on the WebBrowserRefreshOption value specified. If you call the Refresh method with the WebBrowserRefreshOption.Completely value, the latest version of the document is downloaded. If you use the WebBrowserRefreshOption.IfExpired value, the latest version is downloaded only if the current document has expired. If you use the WebBrowserRefreshOption.Normal value, the server sends a copy of the document stored in its own cache.


A document refresh simply reloads the current page, so the Navigating, Navigated, and DocumentCompleted events do not occur when you call the Refresh method.

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.