感谢Hyphen对微信开发的贡献,我有个小问题,望指点
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim signature As String = Request("signature")
Dim timestamp As String = Request("timestamp")
Dim nonce As String = Request("nonce")
Dim echostr As String = Request("echostr")
'Dim udpclient As New MyUDPClient
'udpclient.Send("signature=" & signature & "×tamp=" & timestamp & "&n&echostr=" & echostr)
If Request.HttpMethod = "GET" Then
If Verify(Token, timestamp, nonce, signature) Then
Response.C
Response.Write(echostr) '返回随机字符串则表示验证通过
Response.End()
End If
End If
End Sub
我想收到消息后,直接将消息保存到数据库,该怎么写这个代码?
狐表中的添加数据是这么写的,我该怎么改?
Dim cmd As New SqlCommand
cmd.C
cmd.CommandText = "INSERT INTO 日志记录 (时间,IP地址,计算机名,日志内容) VALUES ('" + Date.Now + "','" + IPAdress.ToString() + "','" + HostName + "','" + s + "')"
cmd.ExecuteNonQuery()
[此贴子已经被作者于2015/11/26 15:16:12编辑过]