+ Reply to Thread
Results 1 to 4 of 4

2nd. argument (Optional ) in COUNTA() function

  1. #1
    Registered User
    Join Date
    11-08-2006
    Posts
    41

    2nd. argument (Optional ) in COUNTA() function

    Hello fellow members!

    I could not make out the purpose of the 2nd. argument; which is optional, in the
    Please Login or Register  to view this content.
    function. Following is the so called help, on this function, from Microsoft:

    A
    Sales
    12/8/2008

    19
    22.24
    TRUE
    #DIV/0

    Formula Description (Result)
    =COUNTA(A2:A8) Counts the number of nonblank cells in the list above (6)
    =COUNTA(A5:A8) Counts the number of nonblank cells in the last 4 rows of the list (4)

    The above results are Ok. But, why are the following 2 examples return 7 each?

    =COUNTA(A1:A7,2) Counts the number of nonblank cells in the list above and the value 2 (7)
    =COUNTA(A1:A7,"Two") Counts the number of nonblank cells in the list above and the value "Two" (7)
    I don't find any value '2' or 'two' in the data; then why are they returning 7 number of values?

    Please help me in making my concept clear.

    Regards,

  2. #2
    Forum Expert sweep's Avatar
    Join Date
    04-03-2007
    Location
    Great Sankey, Warrington, UK
    MS-Off Ver
    2003 / 2007 / 2010 / 2016 / 365
    Posts
    3,444
    Hi,

    There isn't an optional arguement for the COUNTA function. the examples are showing you the following,

    =COUNTA(A1:A7,2) Counts the number of nonblank cells in the list above and the value 2

    the "long hand" equivalent of this is =COUNTA("Sales","12/8/2008","",19,22.24,TRUE,"#DIV/0",2)

    There are 7 nonblank entries in the list



    and
    =COUNTA(A1:A7,"Two") Counts the number of nonblank cells in the list above and the value "Two"

    has a long equivalent =COUNTA("Sales","12/8/2008","",19,22.24,TRUE,"#DIV/0","Two")

    There are 7 nonblank entries in the list.
    Rule 1: Never merge cells
    Rule 2: See rule 1

    "Tomorrow I'm going to be famous. All I need is a tennis racket and a hat".

  3. #3
    Forum Expert sweep's Avatar
    Join Date
    04-03-2007
    Location
    Great Sankey, Warrington, UK
    MS-Off Ver
    2003 / 2007 / 2010 / 2016 / 365
    Posts
    3,444
    Hi,

    There isn't an optional arguement for the COUNTA function. the examples are showing you the following,

    =COUNTA(A1:A7,2) Counts the number of nonblank cells in the list above and the value 2

    the "long hand" equivalent of this is =COUNTA("Sales","12/8/2008","",19,22.24,TRUE,"#DIV/0",2)

    There are 7 nonblank entries in the list



    and
    =COUNTA(A1:A7,"Two") Counts the number of nonblank cells in the list above and the value "Two"

    has a long equivalent =COUNTA("Sales","12/8/2008","",19,22.24,TRUE,"#DIV/0","Two")

    There are 7 nonblank entries in the list.

  4. #4
    Registered User
    Join Date
    11-08-2006
    Posts
    41
    Thanks Dave; for clearifying my one confusion. Still, I could not understand the purpose of this argument.

    Would you help me understand, what value of this argument may produce a different result. I tried every possible value for this argument but the result remains the same (7).

    Thanks in anticipation.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1