FIX THE VISUAL BASIC CODE FOR THE FOLLOWING INSTRUCTIONS:
CODE ABOVE FOR COPY AND PAST
Public Class frmCalculateTax
Private Sub btnExit_Click(sender As Object, e As EventArgs) Handles btnExit.Click
Me.Close()
End Sub
Private Sub btnCalculate_Click(sender As Object, e As EventArgs) Handles btnCalculate.Click
Dim taxableIncome As Decimal = CDec(txtTaxableIncome.Text)
Dim incomeTaxOwed As Decimal
Select Case taxableIncome
Case taxableIncome
End Select
Select Case incomeTaxOwed
Case Is <= 8700
incomeTaxOwed = (0 + taxableIncome * 0.1D)
Case Is <= 35350
incomeTaxOwed = (870 + (taxableIncome - 8700) * 0.15D)
Case Is <= 85650
incomeTaxOwed = (4867 + (taxableIncome - 35350) * 0.25D)
Case Is <= 178650
incomeTaxOwed = (17442 + (taxableIncome - 85650) * 0.28D)
Case Is <= 388350
incomeTaxOwed = (43482 + (taxableIncome - 178650) * 0.33D)
Case Else
incomeTaxOwed = (112683 + (taxableIncome - 388350) * 0.35D)
End Select
'If taxableIncome >= 0 AndAlso taxableIncome <= 8700 Then
'incomeTaxOwed = (0 + taxableIncome * 0.1D)
'ElseIf taxableIncome > 8700 AndAlso taxableIncome <= 35350 Then
'incomeTaxOwed = (870 + (taxableIncome - 8700) * 0.15D)
'ElseIf taxableIncome > 35350 AndAlso taxableIncome <= 85650 Then
'incomeTaxOwed = (4867 + (taxableIncome - 35350) * 0.25D)
'ElseIf taxableIncome > 85650 AndAlso taxableIncome <= 178650 Then
'incomeTaxOwed = (17442 + (taxableIncome - 85650) * 0.28D)
'ElseIf taxableIncome > 178650 AndAlso taxableIncome <= 388350 Then
'incomeTaxOwed = (43482 + (taxableIncome - 178650) * 0.33D)
'ElseIf taxableIncome > 388350 Then
'incomeTaxOwed = (112683 + (taxableIncome - 388350) * 0.35D)
'End If
txtIncomeTaxOwed.Text = incomeTaxOwed.ToString("C")
End Sub
End Class