Exemplo n.º 1
0
 //修改
 void _barbtnUpdate_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
 {
     this.Cursor = Cursors.WaitCursor;
     if (gvData.FocusedRowHandle < 0)
     {
         ControlsHelper.ShowWarningMessage("提醒", "请点击修改的报价");
     }
     else
     {
         QuoteMain quoteMain = (QuoteMain)gvData.GetRow(gvData.FocusedRowHandle);
         FrmQuoteMainEdit frm = new FrmQuoteMainEdit("修改", quoteMain.Guid);
         BindList();
         if (frm.ShowDialog() == DialogResult.OK)
         {
             BindList();
             ControlsHelper.ShowAlertMessage(this.ParentForm, "修改", "修改成功");
         }
     }
     this.Cursor = Cursors.Default;
 }
Exemplo n.º 2
0
        //新增
        void _barbtnInsert_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            this.Cursor = Cursors.WaitCursor;

            FrmQuoteMainEdit frm = new FrmQuoteMainEdit("新增", "");

            if (frm.ShowDialog() == DialogResult.OK)
            {
                BindList();
                ControlsHelper.ShowAlertMessage(this.ParentForm, "新增", "新增成功");
            }
            this.Cursor = Cursors.Default;
        }