private void btn_Kaydet_Click(object sender, EventArgs e) { try { miktar = Convert.ToDecimal(txtMiktar.Text.Trim()); } catch { MessageBox.Show("Miktar alanına sayısal değer giriniz", "HATA"); Utility.selectText(txtMiktar); return; } if (!(miktar > 0)) { return; } Cursor.Current = Cursors.WaitCursor; try { WS_Islem.ZKT_WM_WS_ISLEMService srv = new KoctasWM_Project.WS_Islem.ZKT_WM_WS_ISLEMService(); WS_Islem.ZKtWmWsSigortaCikisi chk = new KoctasWM_Project.WS_Islem.ZKtWmWsSigortaCikisi(); WS_Islem.ZKtWmWsSigortaCikisiResponse resp = new KoctasWM_Project.WS_Islem.ZKtWmWsSigortaCikisiResponse(); chk.IvLenum = txtPaletNo.Text.ToString().Trim(); chk.IvMatnr = malzemeNo; chk.IvMiktar = miktar; chk.IvLgpla = txtAdres.Text.ToString(); chk.IvPrctr = txtKarMerkezi.Text.ToString(); srv.Credentials = GlobalData.globalCr; srv.Url = Utility.getWsUrlForWM("zkt_wm_ws_islem"); resp = srv.ZKtWmWsSigortaCikisi(chk); if (resp.EsResponse.Length > 0) { //Mesajlar düzenleniyor GlobalData.rMsg = new KoctasWM_Project.WS_Islem.ZktWmReturn[resp.EsResponse.Length]; GlobalData.rMsg = Utility.mesajDuzenle(resp.EsResponse); if (GlobalData.rMsg[0].Msgty.ToString().ToUpper() == "E") { MessageBox.Show(GlobalData.rMsg[0].Message.ToString(), "HATA"); Utility.selectText(txtMiktar); } else if ((GlobalData.rMsg[0].Msgty.ToString().ToUpper() == "S") || (GlobalData.rMsg[0].Msgty.ToString().ToUpper() == "W") || (GlobalData.rMsg[0].Msgty.ToString().ToUpper() == "I")) { MessageBox.Show(GlobalData.rMsg[0].Message.ToString(), "BİLGİ"); Utility.moreMsgCheck(GlobalData.rMsg); formAcilisDuzenle(); } else { MessageBox.Show(GlobalData.rMsg[0].Message.ToString(), "BİLİNMEYEN DURUM"); Utility.selectText(txtMiktar); } } else { MessageBox.Show("EsResponse dönüş değeri hatalı", "HATA"); } } catch (Exception ex) { MessageBox.Show(ex.Message, "HATA"); } finally { Cursor.Current = Cursors.Default; } }