在winform中怎样将IE浏览器镶套到窗口中!

greenhill 2003-09-15 11:22:34
我想在winform中打开一个窗口,在窗口中显示某固定的网页?
...全文
32 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
greenhill 2003-09-15
  • 打赏
  • 举报
回复
请问一下:那4个对象是什么意思?
superzuoluo 2003-09-15
  • 打赏
  • 举报
回复
object o1 = null, o2 = null, o3 = null, o4 = null;
webBrowser1.Navigate("c:\\1.html",ref o1,ref o2,ref o3,ref o4);
greenhill 2003-09-15
  • 打赏
  • 举报
回复
那我怎样可以固定打开的某个网页呢??
superzuoluo 2003-09-15
  • 打赏
  • 举报
回复
工具箱-》自定义工具箱-》COM组件-》Microsoft Web 浏览器
superzuoluo 2003-09-15
  • 打赏
  • 举报
回复
Navigates to a resource identified by a URL or to the file identified by a full path.

Syntax

HRESULT Navigate( BSTR url,
VARIANT* Flags,
VARIANT* TargetFrameName,
VARIANT* PostData,
VARIANT* Headers
);
Parameters

url
[in] Required. A BSTR expression that evaluates to the URL, full path, or Universal Naming Convention (UNC) location and name of the resource to display.
Flags
[in] Pointer to 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
[in] Pointer to a string that contains the name of the frame in which to display the resource. The possible values for this parameter are:
_BLANK
Load the link into a new unnamed window.
_PARENT
Load the link into the immediate parent of the document the link is in.
_SELF
Load the link into the same window the link was clicked in.
_TOP
Load the link into the full body of the current window.
<WINDOW_NAME>
A named HTML frame. If no frame or window exists that matches the specified target name, a new window is opened for the specified link.
PostData
[in] Pointer to 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, IWebBrowser2::Navigate issues an HTTP GET transaction. This parameter is ignored if URL is not an HTTPURL.
Headers
[in] Pointer to a value that contains the HTTP headers to send to the server. These headers are added to the default Microsoft® Internet Explorer headers. The headers can specify things such as 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 HTTPURL.
Return Value

Returns one of the following values.

S_OK The operation was successful.
E_INVALIDARG One or more parameters are invalid.
E_OUTOFMEMORY Out of memory.
greenhill 2003-09-15
  • 打赏
  • 举报
回复
这几个参数分别是什么意思?
NekChan 2003-09-15
  • 打赏
  • 举报
回复
References

110,534

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 C#
社区管理员
  • C#
  • Web++
  • by_封爱
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

让您成为最强悍的C#开发者

试试用AI创作助手写篇文章吧