求助大佬,配置企业微信机器人的时候,运行代码出现40008代码,错误的json格式?
Dim http Set http = CreateObject("MSXML2.XMLHTTP") ' 要发送到的URL[图片] url = "https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=XXXXXXXXXXXXXXXXXXXXXXX" ' 准备POST数据 data = "key1=value1&key2=value2" ' 打开连接 http.Open "POST", url, False ' 设置Content-Type http.setRequestHeader "Content-Type", "application/x-www-form-urlencoded" ' 发送数据 http.Send data ' 检查响应 If http.Status = 200 Then ' 请求成功 MsgBox http.responseText Else ' 请求失败 MsgBox "Error: " & http.Status & " - " & http.statusText End If ' 清理 Set http = Nothing