im new in vb and i just create a simple calculation
if i click the button for compute it will display the error
please help me
Dim price As Decimal = txtprice.Text
Dim quantity As Integer = txtquantity.Text
Dim totalprice As Decimal = txttotal.Text
totalprice = quantity * price
working code below
txttotal.Text = Val(txtprice.Text) * Val(txtquantity.Text)