以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.net/bbs/index.asp)
--  专家坐堂  (http://foxtable.net/bbs/list.asp?boardid=2)
----  [求助]对接钉钉,总是时间戳报错  (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=135045)

--  作者:redbule2
--  发布时间:2019/5/15 19:11:00
--  [求助]对接钉钉,总是时间戳报错

图片点击可在新窗口打开查看此主题相关图片如下:时间戳报错.png
图片点击可在新窗口打开查看


图片点击可在新窗口打开查看此主题相关图片如下:引用.png
图片点击可在新窗口打开查看

我写的代码为:

Dim url As String = "https://oapi.dingtalk.com/topapi/processinstance/listids?access_token={0}"
Dim hc As New HttpClient(CExp(url, Functions.Execute("GetAccessToken")))
hc.FormData.Add("process_code","PROC-207L3B0W-0VTU65KJPD54R1QYWSJB3-P03HVOGJ")
hc.FormData.Add("start_time","1496678400000L")
Dim jo As JObject = JObject.Parse(hc.GetData)
If jo("errcode") = "0" Or jo("errmsg") = "ok" Then
    Dim sb As New StringBuilder
    For Each jk As JToken  In jo("data")
       sb.AppendLine(jk)
    Next
    Messagebox.Show(sb.ToString)
Else
    output.Show(jo.ToString)
End If


订单接口文档为:
https://open-doc.dingtalk.com/microapp/serverapi2/hh8lx5

 下载信息  [文件大小:   下载次数: ]
图片点击可在新窗口打开查看点击浏览该文件:钉钉接口.foxdb



[此贴子已经被作者于2019/5/15 19:11:48编辑过]

--  作者:有点甜
--  发布时间:2019/5/16 9:49:00
--  

时间戳要动态的,如

 

Dim st As New Date(1970,1,1,8,0,0)
Dim timestamp As Long = clng((Date.Now - st).TotalSeconds()) \'时间戳
msgbox(timestamp)