This could very well be the most complicated Excel formula I have ever written. It's to pull information from federal tax tables, and to enter the proper tax withholding per bi-weekly pay. For it to work properly it has to calculate the proper withholding allowances and pull the information from the proper tax bracket, and then calculate the amount owed based on bi-weekly income for a married person. It is a single formula, in a single cell. It took several hours for me to get it right, but it's working properly:
=IF(AND(D8-U3>=Z9,D8-U3<Z10),((D8-U3-Z9)*Y9)+X9,IF(AND(D8-U3>=Z10,D8-U3<Z11),((D8-U3-Z10)*Y10)+X10,IF(AND(D8-U3>=Z11,D8-U3<Z12),((D8-U3-Z11)*Y11)+X11,IF(AND(D8-U3>=Z12,D8-U3<Z13),((D8-U3-Z12)*Y12)+X12,IF(AND(D8-U3>=Z13,D8-U3<Z14),((D8-U3-Z13)*Y13)+X13,IF(AND(D8-U3>=Z14,D8-U3<Z15),((D8-U3-Z14)*Y14)+X14,IF(D8-U3>=Z15,((D8-U3-Z15)*Y15)+X15)))))))
I will later modify it to calculate the right bracket for a single vs. married person.
Scuzzy;