Private Sub txtComm_LostFocus()
' Commissie is prijs per eenheid * comm (bv. 0.5) / 100 * eenheid
txtTComm = ((txtPCts * txtComm) / 100) * txtcarts
End Sub
Private Sub txtPCts_LostFocus()
'als het een aankoop betreft dan
If txtSort = "purchase" Then
' font kleur = blauw
txtCarats.ForeColor = vbBlue
txtTotal1.ForeColor = vbBlue
txtTotal2.ForeColor = vbBlue
'uiteindelijke waarde berekenen3.
txtTotal1 = txtCarats * txtPCts
txtTotal2 = txtTotal1 / txtRate
'absolute waarde weergeven
txtTotal1 = Abs(txtTotal1)
txtTotal2 = Abs(txtTotal2)
ElseIf txtSort = "sale" Then
txtCarats.ForeColor = vbRed
txtTotal1.ForeColor = vbRed
txtTotal2.ForeColor = vbRed
txtTotal1 = txtCarats * txtPCts
txtTotal2 = txtTotal1 / txtRate
txtTotal1 = -(Abs(txtTotal1))
txtTotal2 = -(Abs(txtTotal2))
End If
End Sub
Kan er iemand helpen?
' Commissie is prijs per eenheid * comm (bv. 0.5) / 100 * eenheid
txtTComm = ((txtPCts * txtComm) / 100) * txtcarts
End Sub
Private Sub txtPCts_LostFocus()
'als het een aankoop betreft dan
If txtSort = "purchase" Then
' font kleur = blauw
txtCarats.ForeColor = vbBlue
txtTotal1.ForeColor = vbBlue
txtTotal2.ForeColor = vbBlue
'uiteindelijke waarde berekenen3.
txtTotal1 = txtCarats * txtPCts
txtTotal2 = txtTotal1 / txtRate
'absolute waarde weergeven
txtTotal1 = Abs(txtTotal1)
txtTotal2 = Abs(txtTotal2)
ElseIf txtSort = "sale" Then
txtCarats.ForeColor = vbRed
txtTotal1.ForeColor = vbRed
txtTotal2.ForeColor = vbRed
txtTotal1 = txtCarats * txtPCts
txtTotal2 = txtTotal1 / txtRate
txtTotal1 = -(Abs(txtTotal1))
txtTotal2 = -(Abs(txtTotal2))
End If
End Sub
Kan er iemand helpen?