Question about Computers & Internet

The IF() is the wrong one to use. Use "Iif()", as in:

=IiF(A3='Audit Exception Register'!B:B, COUNTIF('Audit Exception Register'!P:P,Y), 0)

See:

http://pubs.logicalexpressions.com/Pub0009/LPMArticle.asp?ID=799

Caveat about using Iif(), one that doesn't probably apply in this case, but keep it in mind: Don't use Iif when trying to return the values of "real" objects. Examples of "non-real" objects in the VB/A world are:

String

Integer, Double, etc... all the numeric "objects"

Boolean

These are fine to use in IIf() statements. If however you will be returning some value that is part of an object, as in:

Iif(x=2, myObject.getSomeVal(), 0)

You run the very real risk that is myObject is null, your program will simply stop running. Iif() will NOT return a null error/exception; it will in fact just stop. This is a bug in the VB interpreter and/or in the Iif() function itself.

I am referring here to classic VBA (ie, pre-VB dot-Net). How .NET handles such cases, I don't know.

Posted on Mar 07, 2008

Hi,

a 6ya expert can help you resolve that issue over the phone in a minute or two.

best thing about this new service is that you are never placed on hold and get to talk to real repairmen in the US.

the service is completely free and covers almost anything you can think of (from cars to computers, handyman, and even drones).

click here to download the app (for users in the US for now) and get all the help you need.

goodluck!

Posted on Jan 02, 2017

COUNTIF(range,criteria)

Counts the number of cells within a range that meet the given condition.

This COUNTIF formula appears to count only the Employees that have the value "F" in the designated container. ie. Female.

Counts the number of cells within a range that meet the given condition.

This COUNTIF formula appears to count only the Employees that have the value "F" in the designated container. ie. Female.

Nov 20, 2013 | Microsoft Excel 2010

Hi, Not sure if this is what you have tried:

1: Assuming each run is on a different column

Run1 Run2 Run3 Run4, etc...and the maxium lenght of each column is 9 values, but each colum has a different lenght of numbers..

Then you can use:

=MAX(COUNTIF(A2:A10,"<>0"),COUNTIF(B2:B10,"<>0"), {keep adding countif for each colum).

If all runs are on the same colum, then using Pivot tables is easier. If you have a copy of your data, please post it so that I can give you the exact formula ;)

1: Assuming each run is on a different column

Run1 Run2 Run3 Run4, etc...and the maxium lenght of each column is 9 values, but each colum has a different lenght of numbers..

Then you can use:

=MAX(COUNTIF(A2:A10,"<>0"),COUNTIF(B2:B10,"<>0"), {keep adding countif for each colum).

If all runs are on the same colum, then using Pivot tables is easier. If you have a copy of your data, please post it so that I can give you the exact formula ;)

Oct 21, 2009 | Microsoft Excel for PC

To reference the first letters in a cell, use the left function. The syntax is =left(cell,#). So, to return the left two letters from cell A1, you use =left(a1,2). You can put that in a cell or incorporate it into some functions.

Jun 12, 2009 | Microsoft Excel for PC

Use the COUNTIF command. The COUNTIF command can count the criteria for a range of cells. Since you can only use it for one range of cells or criteria, you simply add another criteria to the formula as follows: =COUNTIF(AG1:AG5,"X")+COUNTIF(Sheet2!L1:L6,"X")

Apr 10, 2009 | Microsoft Excel for PC

For the same exemple you can try this:

=COUNTIF(A1:A4,"=George Washington School")

=COUNTIF(A1:A4,"=George Washington School")

Apr 03, 2009 | Microsoft Excel for PC

The formula in both versions is the same:

=countif(range,value)

i.e. The below formula will increase its count by one if any of the 18 cells it's checking are equal to 1.

=countif(A1:B9,1)

=countif(range,value)

i.e. The below formula will increase its count by one if any of the 18 cells it's checking are equal to 1.

=countif(A1:B9,1)

Jan 21, 2009 | Microsoft Office Excel 2003 for PC

Apply the following:

COUNT(A3:A74)/COUNTIF(A3:A74,"1")*100 in order to obtain the percentage.

COUNT(A3:A74)/COUNTIF(A3:A74,"1")*100 in order to obtain the percentage.

Nov 26, 2008 | Microsoft Office 2003 Basic Edition...

The solution I've used in similar situations is to create a 3rd column C with the items in column A and column B concatenated.

C2 = A2 & B2

C3 = A3 & B3

C4 = A4 & B4

etc.

Then use COUNTIF function: =COUNTIF(C:C,"FredRed Ball")

Hope this helps.

C2 = A2 & B2

C3 = A3 & B3

C4 = A4 & B4

etc.

Then use COUNTIF function: =COUNTIF(C:C,"FredRed Ball")

Hope this helps.

May 27, 2008 | Microsoft Excel for PC

Lets say your data (cars) is in range "D1:D21".

You need to know how many are Dodge and Ford in cell E1.

=COUNTIF(D1:D21,"Dodge") + COUNTIF(D1:D21,"Ford)

Hope this helps.

You need to know how many are Dodge and Ford in cell E1.

=COUNTIF(D1:D21,"Dodge") + COUNTIF(D1:D21,"Ford)

Hope this helps.

Apr 22, 2008 | Microsoft Excel for PC

You may want COUNTIF if you're specifying criteria. For instance, if my prices are found in b3 to b7, here's a formula that will find all those that are less than 6 ($6.00):

=COUNTIF(B3:B7, "<6")

If you're using multiple criteria, such as you want to find all the prices that are greater than $5 and less than $8, the following will accomplish it. (The ABS gives you the absolute value of the result, in case the smaller number is first.)

=ABS(SUM(COUNTIF(B3:B7, ">5") - COUNTIF(B3:B7, "<8")))

=COUNTIF(B3:B7, "<6")

If you're using multiple criteria, such as you want to find all the prices that are greater than $5 and less than $8, the following will accomplish it. (The ABS gives you the absolute value of the result, in case the smaller number is first.)

=ABS(SUM(COUNTIF(B3:B7, ">5") - COUNTIF(B3:B7, "<8")))

Nov 06, 2007 | Oracle 10g Database Standard (ODBSEONUPP0)

Feb 23, 2017 | Computers & Internet

155 people viewed this question

Usually answered in minutes!

×