This documentation is archived and is not being maintained.

IVsWebBrowsingService.CreateWebBrowser Method

Create an instance of a Web browser within the Visual Studio user interface.

Namespace: Microsoft.VisualStudio.Shell.Interop
Assembly: Microsoft.VisualStudio.Shell.Interop (in

int CreateWebBrowser (
	[InAttribute] uint dwCreateFlags,
	[InAttribute] ref Guid rguidOwner,
	[InAttribute] string lpszBaseCaption,
	[InAttribute] string lpszStartURL,
	[InAttribute] IVsWebBrowserUser pUser,
	out IVsWebBrowser ppBrowser,
	out IVsWindowFrame ppFrame
int CreateWebBrowser (
	/** @attribute InAttribute() */ UInt32 dwCreateFlags, 
	/** @attribute InAttribute() */ /** @ref */ Guid rguidOwner, 
	/** @attribute InAttribute() */ String lpszBaseCaption, 
	/** @attribute InAttribute() */ String lpszStartURL, 
	/** @attribute InAttribute() */ IVsWebBrowserUser pUser, 
	/** @attribute OutAttribute() */ /** @ref */ IVsWebBrowser ppBrowser, 
	/** @attribute OutAttribute() */ /** @ref */ IVsWindowFrame ppFrame
JScript does not support passing value-type arguments by reference.



[in] Bit flags specifying browser options. Created using values from the __VSCREATEWEBBROWSER enumeration.


[in] The GUID of the owner of the window frame in which the browser appears.


[in] Pointer to a string containing the base (first part) of the caption for the browser window. Default is WebBrowser.


[in] Pointer to a string containing the URL of the page to display.


[in] Pointer to the IVsWebBrowserUser interface to use in controlling the browser.


[out] Pointer to the IVsWebBrowser interface of the browser.


[out] Pointer to the window frame (IVsWindowFrame) containing the browser.

Return Value

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

COM Signature

From vsbrowse.idl:

HRESULT IVsWebBrowsingService::CreateWebBrowser(
   [in] VSCREATEWEBBROWSER dwCreateFlags, 
   [in] REFGUID rguidOwner, 
   [in] LPCOLESTR lpszBaseCaption, 
   [in] LPCOLESTR lpszStartURL, 
   [in] IVsWebBrowserUser* pUser, 
   [out] IVsWebBrowser** ppBrowser, 
   [out] IVsWindowFrame** ppFrame