Help with IF Statement please!?

C

Colin

Hi!

I am a novice with this command but think it may be helpful to me in
entering a short code for a tax type in once cell, then depending on
the code input, a total including tax for a transaction is calculated
in another cell.

I hope the following makes sense ....

Headings - Column A is 'Amount (£)', column B is 'Tax Type' and column
C is 'Total Value'.

In column B tax type 'A' is taxable at 17.5% and tax type 'B' is no
tax therefore 0%.

If in cell A3 the transaction amount is entered as £100, in cell B3
the tax type is entered as 'A', I would like a formula entered in C3
that calculates the values as £117.50. However, if tax type B is
entered in B3 instead, then the value in C3 would simply be £100.00.

I understand how to format for currency etc, I include the £ simply
for completeness. Thanks very much for any assistance with this
formula.

Colin.
 
J

John Wilson

Colin,

The following should work for you:

=IF(B1="A",A1*1.17,IF(B1="B",A1,"Neither A or B"))

You could actually shorten the above if B1 has only two choices.
e.g.
=IF(B1="A",A1*1.17,A1)
The above doesn't test for "B" but assumes that it is since
it's not "A". You could expand the IF statement out to 7
nestings. If you need more than that, a lookup table would
be more appropriate.

John
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top