【发布时间】:2013-09-20 04:22:57
【问题描述】:
我有一个返回 DateTime 字段的 WebService。
我得到一个结果/Date(1379048144000)/ 但是
我只想要1379048144000 我怎样才能做到这一点。
[WebMethod]
public DateTime GetServerDate()
{
return DateTime.Now;
}
通过设置Header Content-Type: application/json;字符集=utf-8;我得到了类似/Date(1379048144000)/ 的结果。
【问题讨论】:
标签: c# .net json web-services