Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 6
Default Make cell value zero if cell formula returns value less than zero?

Is there an easy way, such as a format setting, to make a cell value zero if
the cell's formula returns a value less than zero?

I've used a conditional statement with the SIGN function before, but I have
existing cells with formulas that I would just like to apply a format to if
possible.

=IF(SIGN(+L7+N7+P7-K7)=-1,0,+L7+N7+P7-K7)


Thank you,
Fred


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Make cell value zero if cell formula returns value less than zero?

Try this:

=MAX(L7+N7+P7-K7,0)

Hope this helps.

Pete

On Feb 20, 4:49 pm, "Fred Ernst" wrote:
Is there an easy way, such as a format setting, to make a cell value zero if
the cell's formula returns a value less than zero?

I've used a conditional statement with the SIGN function before, but I have
existing cells with formulas that I would just like to apply a format to if
possible.

=IF(SIGN(+L7+N7+P7-K7)=-1,0,+L7+N7+P7-K7)

Thank you,
Fred



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,081
Default Make cell value zero if cell formula returns value less than zero?

Try:

=max(L7+N7+P7-K7,0)

"Fred Ernst" wrote:

Is there an easy way, such as a format setting, to make a cell value zero if
the cell's formula returns a value less than zero?

I've used a conditional statement with the SIGN function before, but I have
existing cells with formulas that I would just like to apply a format to if
possible.

=IF(SIGN(+L7+N7+P7-K7)=-1,0,+L7+N7+P7-K7)


Thank you,
Fred



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
formula for a cell which is blank returns populated cell Gracey1 Excel Discussion (Misc queries) 1 February 2nd 07 09:17 AM
Cell reference in formula always returns a zero value Jim Alderman Excel Discussion (Misc queries) 9 November 28th 06 03:36 PM
Formula returns cell name rjvega Excel Discussion (Misc queries) 1 August 17th 06 08:36 PM
Formula returns cell name Dave F Excel Discussion (Misc queries) 0 August 17th 06 08:35 PM
Formula to sum every 4th cell returns #DIV/0! error in some column Brent Excel Worksheet Functions 5 March 16th 06 07:20 PM


All times are GMT +1. The time now is 04:25 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"