I’m having the following spin button code in my user form
Code: Select all
Private Sub SpinButton2_SpinDown()
txtQty.Value = Format(0, "0.00")
txtQty.Value = txtQty.Value + SpinButton2.Value
txtQty.Value = Format(txtQty.Value, "0")
End Sub
Private Sub SpinButton2_SpinUp()
txtQty.Value = Format(0, "0.00")
txtQty.Value = txtQty.Value + SpinButton2.Value
txtQty.Value = Format(txtQty.Value, "0")
End Sub
The value that should reside in the text box txtTotal is the calculated (multiplied) value from the text box txtRate & txtQty.
What I’m trying to get help is how to change the value on textbox txtTotal(with the help of the spin button) when the quantity gets changed with rate.
Any help would be kindly appreciated.
For example the value on the text box txtrate is 10.00 and quantity is 1. If I change the quantity from 1 to 2 I want the value in txtTotal to be 20.00