Пример #1
0
        private void hlk_Add_Click(object sender, EventArgs e)
        {
            if (lue_gys.EditValue == null)
            {
                XtraMessageBox.Show("请您选择供应商!", "操作提示", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;
            }

            var xf = new IntoStorageDetail()
            {
                _supplierId = int.Parse(lue_gys.EditValue.ToString()),
                _orderNum   = txt_OrderNum.Text.Trim(),
            };

            if (DialogResult.OK == xf.ShowDialog())
            {
                InitGridView();
            }
        }
Пример #2
0
 private void gd_list_DoubleClick(object sender, EventArgs e)
 {
     try
     {
         var frm = new IntoStorageDetail
         {
             _detailId   = Convert.ToInt32(gridView1.GetRowCellValue(gridView1.FocusedRowHandle, "Id")),
             _supplierId = int.Parse(lue_gys.EditValue.ToString()),
             _orderNum   = txt_OrderNum.Text.Trim(),
         };
         if (DialogResult.OK == frm.ShowDialog())
         {
             InitGridView();
         }
         else
         {
             XtraMessageBox.Show("编辑失败!", "操作提示", MessageBoxButtons.OK, MessageBoxIcon.Error);
         }
     }
     catch (Exception ex)
     {
         XtraMessageBox.Show("编辑出错!" + ex.Message);
     }
 }