Excel - Formula query?

Asked By Steve on 15-May-12 12:53 PM
Hi could anyone please help with this formula/

=IF(AND(K10="Standard",AH>0),1,0)+AI103590

The formula works fine as is but I now have three different additional
standards

KStandard
WStandard
SStandard

so I would like the formula to work if either of three above are
mentioned in K10.

Is there a wildcard I can put in front of Standard that would pick up
all three types? I have tried ?Standard but i get an error.

Any help appreciated

Thanks

Steve


Claus Busch replied to Steve on 15-May-12 01:08 PM
Hi Stece,

Am Tue, 15 May 2012 17:53:53 +0100 schrieb Steve:


try:
=IF(AND(COUNTIF(K10,"*Standard")=1,AH10>0),1,0)
or
=IF(AND(RIGHT(K10,8)="Standard",AH10>0),1,0)
or
=IF(AND(OR(K10="KStandard",K10="SStandard",K10="Wstandard"),AH10>0),1,0)


Regards
Claus Busch
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2
joeu2004 replied to Steve on 15-May-12 02:25 PM
One way (among many):

=AND(OR(K10={"KStandard","WStandard","SStandard"}),AH10>0)+AI103590

Note that you really do not an IF express that returns 1 or 0 becuase TRUE
and FALSE are converted to 1 and 0 respectively when combined
arithmetically.

Also note that I assume "AH>0" was a typo.  I changed it to AH10>0.
cubbybear3 replied to joeu2004 on 17-May-12 06:30 PM
This might also work, but as joeu2004 pointed out, I will assume the
And since your IF statement has NO "value if false", I am just using
the values True/False.

=if(and(upper(mid(trim(K10),2,8))="STANDARD",AH10>0),"True","False")
Steve replied to Claus Busch on 23-May-12 07:06 AM
Claus thank you so much for your help, that worked perfectly :)

Much apreciated.

Steve
Steve replied to joeu2004 on 23-May-12 08:10 AM
Sorry I didnt see your reply

Thanks, much appreciated

steve
Steve replied to cubbybear3 on 23-May-12 08:11 AM
Sorry I didnt see your reply

Thanks, much appreciated

steve