View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
T. Valko T. Valko is offline
external usenet poster
 
Posts: 15,768
Default Using the Question Mark With COUNTIF

I am curious as to whether or not the "?"
can be used with COUNTIF.


Yes it can.

Try it like this:

=COUNTIF(D11:D33,"~?")

The tilde is an "escape character". It tells Excel to look for the literal
character "?" and not to evaluate it as the wildcard character ?.

--
Biff
Microsoft Excel MVP


"Thomas M." wrote in message
...
Excel 2007

I have a small table that shows me the status of each item on the list.
The status can be "Y", "N", "NA", or "?". I am using the COUNTIF function
to tell me how many of each status is on the list. For items with a
status of "?", which denotes an unknown status, I simply take the total
number of items on the list and subtract the sum of the other status
values to arrive at a count of items with an unknown status. This works
fine.

However, I am curious as to whether or not the "?" can be used with
COUNTIF. I've tried the following:

=COUNTIF(D11:D33,"=?")

Figuring that the question mark is a special character and that a special
syntax might be needed in order make Excel interpret it literally, I've
played around with different variations using single and double quotes,
but I've been unable to make the formula work.

Is it possible to use "?" with COUNTIF, and if so what is the correct
syntax?

Thanks for any help that you can offer.

--Tom