private void FormMakePayment_Load(object sender, System.EventArgs e) { lkpEdtPaymentGroup.EditValue = myPaymentGroupCode; if (lkpEdtPayment.Text == "") { lkpEdtPayment.ItemIndex = 0; } //Derek Instalment Plan decimal outStandingAmt = myPOS.MOutstandingAmount; decimal remainder; if (lkpEdtPayment.Text == "CASH") { remainder = myPOS.MTotalAmount % ACMS.Convert.ToDecimal(0.05); //myPOS.MTotalAmount = myPOS.MTotalAmount - remainder; //txtEdtPaymentAmt.EditValue = myPOS.MTotalAmount.ToString(); txtEdtPaymentAmt.EditValue = (myPOS.MTotalAmount - remainder).ToString(); } else if (lkpEdtPayment.Text == "CASHVOUCHER") { txtEdtPaymentAmt.Enabled = false; txtEdtPaymentAmt.EditValue = "0"; } else { txtEdtPaymentAmt.EditValue = outStandingAmt; } txtEdtPaymentAmt.SelectAll(); }
private void FormMakePayment_Load(object sender, System.EventArgs e) { lkpEdtPaymentGroup.EditValue = myPaymentGroupCode; if (lkpEdtPayment.Text == "") { lkpEdtPayment.ItemIndex = 0; } decimal outStandingAmt = myPOS.MOutstandingAmount; decimal remainder; if (lkpEdtPayment.Text == "CASH") { remainder = myPOS.MTotalAmount % ACMS.Convert.ToDecimal(0.05); myPOS.MTotalAmount = myPOS.MTotalAmount - remainder; txtEdtPaymentAmt.EditValue = myPOS.MTotalAmount.ToString(); } else { txtEdtPaymentAmt.EditValue = outStandingAmt; } txtEdtPaymentAmt.SelectAll(); }
private void setedtNum(DevExpress.XtraEditors.TextEdit edt) { TCombo comb = (TCombo)edt.Tag; if (comb.Endnum == 1) { for (int i = 0; i <= combocontrols.Count - 1; i++) { TComboFromControl cfc = (TComboFromControl)combocontrols[i]; if (((TCombo)cfc.edt.Tag).Columnid == comb.Columnid) { cfc.edt.Text = ""; } } edt.Text = "1"; edt.SelectAll(); } }
/// <summary> /// 텍스트 박스에 대한 숫자를 확인하고 메세지를 출력한다 /// </summary> /// <param name="txtBox"> 유효성검사할 텍스트 박스 </param> public static void IsNumberCheck(DevExpress.XtraEditors.TextEdit txtBox) { try { string strTemp = txtBox.Text.Trim().Replace(",", ""); if (strTemp == "") { return; } if (IsNumeric(strTemp)) { return; } txtBox.Focus(); txtBox.SelectAll(); Basic.ShowMessage(2, "숫자로 입력 하세요"); } catch (Exception ex) { throw ex; } }
private void textEdit_Enter(object sender, EventArgs e) { DevExpress.XtraEditors.TextEdit edit = sender as DevExpress.XtraEditors.TextEdit; BeginInvoke(new Action(() => edit.SelectAll())); }
private void edtNum1_Enter(object sender, EventArgs e) { focusEdt = (DevExpress.XtraEditors.TextEdit)sender; focusEdt.SelectAll(); setedtNum(focusEdt); }