void calculatedData() { try { DateTime sd = startDatePicker.Date + startTime; DateTime ed = endDatePicker.Date + endTime; if (DateTime.Compare(sd, ed) >= 0) { CrossHud.Current.ShowError(message: "开始时间必须早于结束时间", timeout: new TimeSpan(0, 0, 4)); return; } string url = App.BaseURL + "AppFlow/ComputedFlowAllWater"; string parama = "flowid=" + _flow.flowid + "&" + "sdt=" + sd.ToString("yyyy-MM-dd HH:mm") + "&" + "edt=" + ed.ToString("yyyy-MM-dd HH:mm") + "&" + "para1=" + entry1.Text + "&" + "para2=" + entry2.Text; Console.WriteLine("请求接口:" + url); string result = EasyWebRequest.sendOtherPOSTHttpWebRequest(url, parama); Console.WriteLine("请求结果:" + result); calculated = JsonConvert.DeserializeObject <calculatedResult>(result); } catch (Exception ex) { } }