Esempio n. 1
0
        private void CapNhatCTTM()
        {
            try
            {
                QLThuChi.Dao.ThuChi.chungtutienmatRow row = (QLThuChi.Dao.ThuChi.chungtutienmatRow)((DataRowView)this.chungtutienmatBindingSource.Current).Row;
                row.UserId = this.UserId;

                this.chungtutienmatBindingSource.EndEdit();
                this.thuChi.chungtutienmat.GetChanges();
                this.chungtutienmatTableAdapter.Update(this.thuChi.chungtutienmat);
                this.thuChi.chungtutienmat.AcceptChanges();
            }
            catch (Exception ex)
            {
                MessageBox.Show("Xuất hiện lỗi trong khi cập nhật dữ liệu. Xin vui lòng thử lại.", "Error", MessageBoxButtons.OK);
                TraceListenerLogger.Error(ex);
            }
        }