HELP...on my IF formula

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi - I'm trying to figure out a problem I'm having with my IF formula. See
below, I had to add "yr" after my numbers or else it came up blank. I want to
be able to put in just the number 1, 2, 3, 4 or 5 with out the yr behind it
and figure out my percent. Can someone please help me? Thanks in advance!

=IF(C19="1yr",1%,IF(C19="2yr",2%,IF(C19="3yr",3%,IF(C19="4yr",4%,IF(C19="5yr",5%,"")))))
 
Do you need the IF?

=C19*0.01 will give %

Or if C19="1yr"

then =LEFT(C19,1)*0.01
 
Hi Kim,

format c19 as custom like 0 "yr"

you will have C19 value like 1 yr but the value will be 1, so you could type
your formula without the yr.

hth
regards from Brazil
Marcelo

"Kim" escreveu:
 
Kim said:
Hi - I'm trying to figure out a problem I'm having with my IF
formula. See below, I had to add "yr" after my numbers or else it
came up blank. I want to be able to put in just the number 1, 2, 3, 4
or 5 with out the yr behind it and figure out my percent. Can someone
please help me? Thanks in advance!

=IF(C19="1yr",1%,IF(C19="2yr",2%,IF(C19="3yr",3%,IF(C19="4yr",4%,IF(C19="5yr",5%,"")))))

Hi Kim,

You can try this way:

=IF(ISNA(VLOOKUP(VALUE(LEFT(C19,1)),{1,0.01;2,0.02;3,0.03;4,0.04;5,0.05},2,0)),"",VLOOKUP(VALUE(LEFT(C19,1)),{1,0.01;2,0.02;3,0.03;4,0.04;5,0.05},2,0))


--
Hope I helped you.

Thanks in advance for your feedback.

Ciao

Franz Verga from Italy
 
If I understand correctly, try this. You may have had the 1, 2, 3...etc. in
quotes.

=IF(C19=1,1%,IF(C19=2,2%,IF(C19=3,3%,IF(C19=4,4%,IF(C19=5,5%,"")))))

HTH
Regards,
Howard
 

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

Back
Top