Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How do a create a conditional formula in Excel?

0 views
Skip to first unread message

Danno

unread,
Oct 15, 2008, 2:49:04 PM10/15/08
to
I want to create a column that enters an amount automatically based on the
amount in the same row adjacent to this column. ie.) IF D4>30, enter 30 in
E4. and IF D4<0, enter 0 in E4, and if D4 is between 0 and 30, copy that
amount to E4. Sorry I'm so ignorant in Excel but I'm still learning. This
has to be an easy formula to create, I just don't know how. Any help out
there?

John C

unread,
Oct 15, 2008, 2:58:02 PM10/15/08
to
=IF(D4="","",MAX(MIN(30,D4),0))

This assumes that D4 is either blank, or will have a number in it.
--
John C

muddan madhu

unread,
Oct 15, 2008, 3:01:49 PM10/15/08
to
try this

in E4 put this formula
=IF(D4>30,30,IF(D4<0,0,IF(AND(D4>=0,D4<=30),D4,"")))

Bob I

unread,
Oct 15, 2008, 3:02:27 PM10/15/08
to
perhaps you should look up "IF" in Excel Help, and review the examples
provided. That will help you understand the way to do it.

John C

unread,
Oct 15, 2008, 3:04:02 PM10/15/08
to
Actually, this one is much cleaner.
=MIN(MAX(D4,0),30)
--
John C

Danno

unread,
Oct 15, 2008, 3:40:23 PM10/15/08
to
Thanks a bunch guys! All of them work great so I'll just use the simplest
form. Thanks John!

John C

unread,
Oct 15, 2008, 4:15:04 PM10/15/08
to
You are welcome, and thanks for the feedback.
0 new messages