直接跟在URL后面发过去不行吗?
解决方案 »
- 请问为啥CreateDIBSection后用bitblt截图,但是数据指针所指的位置为0
- 如何捕获打印机是否工作
- textbox是否存在“回车”事件?!
- treeview 问题
- Access2000这样连接不行,Data1.Connect = ";pwd=111" 说不能识别数据库,但是access97的数据库可以为什么?
- 请问怎样编写代码插入新的数据,我是新手,请写的详细一点
- 在运行中怎样改变line、 shape 控件的大小、位置?
- 怎样向下层窗体发送消息??就是将本窗体接受的消息原封不动的传递到下一层去??
- 龙之杰论坛里的《剑侠情缘》之《月影传说》专贴也好热啊!
- 关于 在WINDOWCE 环境里开发 主要要用到那方面的知识和指南 请大家介绍一下~~!!!
- 如何添加图标到MDI窗体的菜单,是否可以?
- 在动态控件数组中,如果想循环按键得事件,不是又循环了一边 load控件 吗?
Option ExplicitPrivate Sub Command1_Click()
Dim szValue As String
WebBrowser1.Document.body.innerHTML = "<form id=post method=post action=http://地址/xxx.php><input type=text value='" & szValue & "'></form>"
WebBrowser1.Document.Forms("post").submit
End SubPrivate Sub Form_Load()
WebBrowser1.Navigate2 "about:blank"
End Sub
其中PostData参数就是一个提交参数字符串,例如"name=aaa&password=123",但问题是为什么这个方法并不是有效的,服务器端不能取得数据?
如果这个方法是有效的话就不需要用一段html代码模拟这种调用了。
Syntax
object.Navigate2 URL [Flags,] [TargetFrameName,] [PostData,] [Headers]Part Description
object Required. An object expression that evaluates to an object in the Applies To list.
URL Required. A string expression that evaluates to the URL of the resource to display or the full path to the file location.
Flags Optional. A constant or value that specifies whether to add the resource to the history list, whether to read from or write to the cache, and whether to display the resource in a new window. It can be a combination of the following constants or values. Constant Value Meaning
navOpenInNewWindow 1 Open the resource or file in a new window.
navNoHistory 2 Do not add the resource or file to the history list. The new page replaces the current page in the list.
navNoReadFromCache 4 Do not read from the disk cache for this navigation.
navNoWriteToCache 8 Do not write the results of this navigation to the disk cache.
TargetFrameName Optional. String expression that evaluates to the name of an HTML frame in URL to display in the browser window. 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 Optional. Data to send to the server during the HTTP POST transaction. For example, the POST transaction is used to send data gathered by an HTML form to a program or script. If this parameter does not specify any post data, the Navigate2 method issues an HTTP GET transaction. This parameter is ignored if URL is not an HTTP URL.
Headers Optional. A value that specifies additional 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.
Applies ToInternetExplorer, WebBrowser
PostData Optional. Data to send to the server during the HTTP POST transaction. For example, the POST transaction is used to send data gathered by an HTML form to a program or script. If this parameter does not specify any post data, the Navigate2 method issues an HTTP GET transaction. This parameter is ignored if URL is not an HTTP URL.