Hello,
I have an inquiry in a userform, if you may help me
I have the following textboxes that calculate some values
txtAmount has a calculation which I have the code for it and all the below text boxes as well, unless the "txtPaid"
I need "txtPaid" to be the same as the "txtTotal" but to be able to change it's value
ex: if txtTotal.value = 100, then, txtPaid.value = 100, and then I can change the value of the txtPaid if I need
Code:
Private Sub txtDiscount_Change()
Call txtTotal_Change
End Sub
Private Sub txtTotal_Change()
Me.txtTotal = Me.txtAmount - Me.txtDiscount
Call txtPaid_Change
Call txtRest_Change
End Sub
Private Sub txtPaid_Change()
Me.txtPaid.Text = Me.txtTotal 'I've tried this but I can't change the value
Call txtRest_Change
End Sub
Private Sub txtRest_Change()
Me.txtRest = Me.txtTotal - Me.txtPaid
End Sub
I have an inquiry in a userform, if you may help me
I have the following textboxes that calculate some values
txtAmount has a calculation which I have the code for it and all the below text boxes as well, unless the "txtPaid"
I need "txtPaid" to be the same as the "txtTotal" but to be able to change it's value
ex: if txtTotal.value = 100, then, txtPaid.value = 100, and then I can change the value of the txtPaid if I need
Code:
Private Sub txtDiscount_Change()
Call txtTotal_Change
End Sub
Private Sub txtTotal_Change()
Me.txtTotal = Me.txtAmount - Me.txtDiscount
Call txtPaid_Change
Call txtRest_Change
End Sub
Private Sub txtPaid_Change()
Me.txtPaid.Text = Me.txtTotal 'I've tried this but I can't change the value
Call txtRest_Change
End Sub
Private Sub txtRest_Change()
Me.txtRest = Me.txtTotal - Me.txtPaid
End Sub