Пример #1
0
        private void button2_Click(object sender, EventArgs e)
        {
            string str = "";
            bool   ob  = WCFHelper.WebHttpPost(this.tb_SvrAddr.Text.Trim(), this.tb_json.Text.Trim(), out str);

            if (ob == null)
            {
            }
        }
Пример #2
0
        private void button2_Click(object sender, EventArgs e)
        {
            string str = "";
            bool   ob  = WCFHelper.WebHttpPost(this.tb_SvrAddr.Text.Trim(), this.tb_json.Text.Trim(), out str);
            Dictionary <string, string> dic = new Dictionary <string, string>();

            //dic.Add("method","puApi");

            dic.Add("method", "produceApi");
            dic.Add("param", this.tb_json.Text.Trim());
            str = APIRequst.Send("POST", this.tb_SvrAddr.Text.Trim(), dic);

            str = SendToErp(this.tb_SvrAddr.Text.Trim(), "MaterialInfo", this.tb_json.Text.Trim());
            //var jObject = JObject.Parse(str);
            //string desc = jObject["Desc"].ToString();
            //if(desc!="")
            //{ }
            //ErpResponse erpRes = (ErpResponse)Newtonsoft.Json.JsonConvert.DeserializeObject(str);
            MessageBox.Show(str);
        }