Private Sub btnCalc_Click(sender As System.Object, e As System.EventArgs) Handles btnCalc.Click CalculateCost() End Sub Private Sub CalculateCost() txtbCat1Cost.Text = txtbCat1Items.Text * txtbCat1Price.Text txtbCat2Cost.Text = txtbCat2Items.Text * txtbCat2Price.Text txtbCat3Cost.Text = txtbCat3Items.Text * txtbCat3Price.Text txtbCat4Cost.Text = txtbCat4Items.Text * txtbCat4Price.Text txtbTotalCost.Text = Val(txtbCat1Cost.Text) + Val(txtbCat2Cost.Text) + Val(txtbCat3Cost.Text) + Val(txtbCat4Cost.Text) txtbFinalCost.Text = Val(txtbTotalCost.Text) If chkbLoyalty.CheckState = CheckState.Checked Then txtbCat1Items.Text = txtbCat1Items.Text + 1 txtbTotalCost.Text = txtbTotalCost.Text - 4.0 End If If chkbStaff.CheckState = CheckState.Checked Then txtbFinalCost.Text = txtbFinalCost.Text * 0.9 ElseIf chkbStaff.CheckState = CheckState.Unchecked Then txtbFinalCost.Text = txtbFinalCost.Text End If End Sub Private Sub btnCat1Plus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat1Plus.Click txtbCat1Items.Text = txtbCat1Items.Text + 1 End Sub Private Sub btnCat1Minus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat1Minus.Click If txtbCat1Items.Text > 0 Then txtbCat1Items.Text = txtbCat1Items.Text - 1 ElseIf txtbCat1Items.Text < = 0 Then txtbCat1Items.Text = "0" End If End Sub Private Sub btnCat2Plus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat2Plus.Click txtbCat2Items.Text = txtbCat2Items.Text + 1 End Sub Private Sub btnCat2Minus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat2Minus.Click If txtbCat2Items.Text > 0 Then txtbCat2Items.Text = txtbCat2Items.Text - 1 ElseIf txtbCat2Items.Text < = 0 Then txtbCat2Items.Text = "0" End If End Sub Private Sub btnCat3Plus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat3Plus.Click txtbCat3Items.Text = txtbCat3Items.Text + 1 End Sub PrivateSub btnCat3Minus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat3Minus.Click If txtbCat3Items.Text > 0 Then txtbCat3Items.Text = txtbCat3Items.Text - 1 ElseIf txtbCat3Items.Text < = 0 Then txtbCat3Items.Text = "0" End If End Sub Private Sub btnCat4Plus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat4Plus.Click txtbCat4Items.Text = txtbCat4Items.Text + 1 End Sub Private Sub btnCat4Minus_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCat4Minus.Click If txtbCat4Items.Text > 0 Then txtbCat4Items.Text = txtbCat4Items.Text - 1 ElseIf txtbCat4Items.Text < = 0 Then txtbCat4Items.Text = "0" End If End Sub End Class