IWebBrowser2::NavigateIWebBrowser2::Navigate*
*Contents  *Index  *Topic Contents
*Previous Topic: IWebBrowser2::GoSearch
*Next Topic: IWebBrowser2::Navigate2

IWebBrowser2::Navigate

HRESULT IWebBrowser2::Navigate(
    BSTR URL,
    VARIANT FAR* Flags,
    VARIANT FAR* TargetFrameName,
    VARIANT FAR* PostData,
    VARIANT FAR* Headers,
);

Navigates to a resource identified by a Uniform Resource Locator (URL) or to the file identified by a full path.

URL
A caller-allocated string that contains the URL to navigate to or the full path of the file to display.
Flags
Address of a variable that specifies whether to add the resource to the history list, whether to read to or write from the cache, and whether to display the resource in a new window. The variable can be a combination of the values defined by the BrowserNavConstants enumeration.
TargetFrameName
Address of a string that contains the name of the frame in which to display the resource.
PostData
Address of data to send with the HTTP POST transaction. For example, the POST transaction is used to send data gathered by an HTML form. If this parameter does not specify any post data, Navigate issues an HTTP GET transaction. This parameter is ignored if URL is not an HTTP URL.
Headers
Address of a value that specifies the HTTP headers to send to the server. These headers are added to the default Internet Explorer headers. The headers can specify things like the action required of the server, the type of data being passed to the server, or a status code. This parameter is ignored if URL is not an HTTP URL.

The post data specified by PostData is passed as a SAFEARRAY structure. The variant should be of type VT_ARRAY and point to a SAFEARRAY. The SAFEARRAY should be of element type VT_UI1, dimension one, and have an element count equal to the number of bytes of post data.

Applies To

WebBrowser, Internet Explorer

See also DWebBrowserEvents2::BeforeNavigate2, DWebBrowserEvents2::NavigateComplete2


Up Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.