View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.newusers
Anastasio Jimenez Anastasio Jimenez is offline
external usenet poster
 
Posts: 4
Default If all cells in a range are N/A, then N/A?

HI folks, thanks for the wonderful resource here. I've found a lot of answers
but I had to ask this one ...

I'm working on a spreadsheet that tallies if certain criteria have been met.

Range N15:N31 has three possible answers Y, N or N/A

In cell N32, I tally all the possible answers
=COUNTIF(N15:N31,"Y")+COUNTIF(N15:N31,"N")

In Cell N33 I tally the percentage of answers that are Y
=COUNTIF(N15:N31,"Y")/N32

In Cell N33 I tally the percentage of answers that are N
=COUNTIF(N15:N31,"N")/N32

ISSUE
I've run into the situation of having "div/0" because sometimes all cells in
the range are N/A.

QUESTION
Is there a way to keep the functionality I have but add "if all in range are
N/A, enter N/A"?

Thanks in advance!