Count cells that do not contain a specific value

Range Reference:
Specific Value:
enter the cell reference that contains the value that you want to count for if it doesn't exist:
Formula:

=COUNTIF(B5:B7,"<>"&"*D5*")
=COUNTIF(B5:B7,"<>"&"*"&D5&"*")