I want to find the nearest value of a range EXCLUDING the blank cells in a range. I have managed to get it done but it includes the blanks as they considered with zero's
this is the one that works that includes blanks

```
=INDEX(B9:GS9,MATCH(MIN(ABS(B9:GS9-D1)),ABS(B9:GS9-D1),0))

```

I've also tried to do MINIFS with criteria "<>" but it pops the error window. and also in addition to final solution, a VBA code of it would be great. Thank you.