Esempio n. 1
0
        private void TextBoxes_TextChanged(object sender, EventArgs e)
        {
            TextBox tb;

            if (sender is TextBox)
            {
                tb = (TextBox)sender;
                if (tb == txtSoLuong)
                {
                    //xử lý khi user xóa hết
                    if (string.IsNullOrEmpty(txtSoLuong.Text))
                    {
                        this.SoLuong = 0;
                    }
                    lblThanhTien.Text = string.Format("{0:0,0.00}đ", epKimPres.ThanhTien_ThPh());
                    lblGiaTB.Text     = string.Format("{0:0,0.00}đ", epKimPres.GiaTB_ThPh());
                }
            }
        }
 private void CapNhatLabelGia()
 {
     lblThanhTien.Text = string.Format("{0:0,0.00}đ", epKimPres.ThanhTien_ThPh());
     lblGiaTB.Text     = string.Format("{0:0,0.00}đ/{1}", epKimPres.GiaTB_ThPh(), this.DonViTinh);
 }