ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   formula for a cell which is blank returns populated cell (https://www.excelbanter.com/excel-discussion-misc-queries/128897-formula-cell-blank-returns-populated-cell.html)

Gracey1

formula for a cell which is blank returns populated cell
 
I am writing a formula to return a minimum value from an array of cells, but
if the cells are blank it does not return any value, how can I rectify this,
shown is my formula.
=IF(AT12=0,MIN(M12,AT12,AP12))
M and AT are populated and when I take out AP it returns the lower value,
but when I enter AP which is a formula returning no answer, my other formula
returns a blank cell.


Martin Fishlock

formula for a cell which is blank returns populated cell
 
Hi Gracey1:

Try this:

=IF(AT12=0,MIN(M12,AT12,if(AP12="",M12,AP12)),??? )

note the ??? is the vaue if AT12 < 0

As you say M12 and AT12 are values and should be numbers so therefore if
AP12 is blank replace it with M12 as that is one of the min values.

--
Hope this helps
Martin Fishlock, Bangkok, Thailand
Please do not forget to rate this reply.


"Gracey1" wrote:

I am writing a formula to return a minimum value from an array of cells, but
if the cells are blank it does not return any value, how can I rectify this,
shown is my formula.
=IF(AT12=0,MIN(M12,AT12,AP12))
M and AT are populated and when I take out AP it returns the lower value,
but when I enter AP which is a formula returning no answer, my other formula
returns a blank cell.



All times are GMT +1. The time now is 05:39 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com