# Thread: Tax Function (Excel 2000)

1. ## Tax Function (Excel 2000)

I know I had this worked out at one time, but for the life of me, it's driving me nuts this morning. Could anyone take a quick look at the function below and tell me why it isn't giving me the right figures and how to adjust it for it to work correctly?

Public Function tax(income As Single)
Select Case income
Case Is <= 2500
tax = 0
Case Is <= 5000
tax = (5000 - 2500) * 0.05
Case Is > 5000
tax = (income - 5000) * 0.1 + 125
End Select
End Function

Thank you,
NMP

2. ## Re: Tax Function (Excel 2000)

Shouldn't it be :
Public Function tax(income As Single)
Select Case income
Case Is <= 2500
tax = 0
Case Is <= 5000
tax = (income - 2500) * 0.05
Case Is > 5000
tax = (income - 5000) * 0.1 + 125
End Select
End Function

3. ## Re: Tax Function (Excel 2000)

Francois,

Yes. It is a Monday after all.

Thank you,

NMP

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•