Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / New Users / July 2007

Tip: Looking for answers? Try searching our database.

Greater, equal to or less than question

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Mag()() - 14 Jul 2007 04:11 GMT
I need to write a formula and I am little stuck with it. I have a
requirement to write a formula which has  to state the following....

Where "cell a1" is less than 16 then "less" where "cell a1"  is greater that
16 BUT less than 32 then  "50%" where "cell a1" is equal to or greater than
32 then "OK"

Hope this is clear and hope someone can help me as I have been  stuck  with
this fora while now.

Plz help

mag()()
T. Valko - 14 Jul 2007 04:32 GMT
You've left out 2 possible conditions:

=16 and an empty cell 0

If the cell is empty it will evaluate as 0. 0 is <16 so "Less" would be the
returned value.

You define <16 and >16 but not =16.

Try this with the first condition being <=16:

=IF(ISNUMBER(A1),IF(A1<=16,"Less",IF(A1<32,50%,"OK")),"")

If you want the 50% to be a numeric value then format the cell as
PERCENTAGE. If you want the 50% to be a TEXT value enclose it in quotes in
the formula: "50%".

Using the ISNUMBER test takes care of 2 potential problems. It takes care of
the empty cell situation and it also prevents an incorrect result if a text
entry is accidentally made in the cell.

Signature

Biff
Microsoft Excel MVP

>I need to write a formula and I am little stuck with it. I have a
>requirement to write a formula which has  to state the following....
[quoted text clipped - 9 lines]
>
> mag()()
Stan Brown - 14 Jul 2007 11:37 GMT
Sat, 14 Jul 2007 04:11:42 +0100 from Mag()()
<mrmagoo_ukNOSPAM@hotmail.com>:
> I need to write a formula and I am little stuck with it. I have a
> requirement to write a formula which has  to state the following....
>
> Where "cell a1" is less than 16 then "less" where "cell a1"  is greater that
> 16 BUT less than 32 then  "50%" where "cell a1" is equal to or greater than
> 32 then "OK"

Write it pretty much how you said it:

=if(A1<16,"less",if(A1<32,"50%","greater"))

You left out the =16 case, by the way. I lumped it in with 16-32.

Signature

Stan Brown, Oak Road Systems, Tompkins County, New York, USA
                                 http://OakRoadSystems.com/

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.