asp怎么将查到信息放到一个结果集里,当一个返回值返回
functiontest()sql="select*from[基本信息]where纳税人识别号='"&usercode&"'"rs.opensql,conn,1,1use...
function test()
sql="select * from [基本信息] where 纳税人识别号='"&usercode&"' "
rs.open sql,conn,1,1
username=rs("纳税人名称")
djkind=rs("登记注册类型")
staute=rs("纳税人状态")
rs.close
set rs = nothing
conn.close
set conn = nothing
end function
怎么在我前面的页面接到这个 test () 展开
sql="select * from [基本信息] where 纳税人识别号='"&usercode&"' "
rs.open sql,conn,1,1
username=rs("纳税人名称")
djkind=rs("登记注册类型")
staute=rs("纳税人状态")
rs.close
set rs = nothing
conn.close
set conn = nothing
end function
怎么在我前面的页面接到这个 test () 展开
1个回答
展开全部
Private Function httpPost(ByVal content As String, ByVal url As String) As String
Try
Dim sPostData As String = content '要post的内容
Dim ByteArray As Byte() = System.Text.Encoding.UTF8.GetBytes(sPostData) 'utf8
Dim hwRequest As HttpWebRequest = WebRequest.Create(url) '发送到的运程地址
hwRequest.Method = "POST"
hwRequest.ContentType = "application/x-www-form-urlencoded"
hwRequest.ContentLength = ByteArray.Length
Dim newStream As Stream = hwRequest.GetRequestStream()
newStream.Write(ByteArray, 0, ByteArray.Length)
newStream.Close()
'获得响应
Dim response As HttpWebResponse = hwRequest.GetResponse
newStream = response.GetResponseStream
Dim reader As New StreamReader(newStream)
Dim str As String = reader.ReadToEnd '响应字符串
reader.Close()
newStream.Close()
response.Close()
Return str
Catch ex As Exception
Return ex.Message
End Try
End Function
追问
能解释一下吗?没看明白
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询