+ Reply to Thread
Results 1 to 4 of 4

Thread: Countif

  1. #1
    Registered User
    Join Date
    08-17-2010
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2003
    Posts
    7

    Countif

    In on cell I have following formula =COUNTIF($N8:$EP8, "V")
    It counts cells which contain "V"
    I have to modify this formula - and need your help.
    In my cells ($N8:$EP8) I can have for example 1V or 2V or 6V
    How to count "Vs" , for example, one cell "2V" other cell "5V" - resoult = 7
    It should counts only numbers with suffix "V"
    THanks in Advance

  2. #2
    Valued Forum Contributor dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    New Delhi, India
    MS-Off Ver
    Excel 1997, 2000, XP, 2003, 2007, 2010
    Posts
    2,365

    Re: COUNTIF Help Please

    Hi Amada,

    One quick solution could be You can use Substitute function or Replace command (Ctrl + H) to remove V from the text e.g., 2V , 5V etc and they you can simply sum the numbers in the respective range. Thanks.

    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    DILIPandey
    +919810929744
    dilipandey@gmail.com

  3. #3
    Registered User
    Join Date
    01-23-2012
    Location
    Michigan
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: COUNTIF Help Please

    This should work:

    Starting in cell n10 enter this formula: =IF(RIGHT(N8,1)="V",VALUE(LEFT(N8,LEN(N8)-1)),0)

    Copy this formula to every cell in row 10 to EP10

    Enter this formula in cell N12: =SUM(N10:EP10)

    This will add up the numeric predecessor to "V" for all cells that contain a "V".

  4. #4
    Forum Moderator daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2007
    Posts
    10,053

    Re: COUNTIF Help Please

    You could use an "array formula" like this

    =SUM(IF(RIGHT(N8:EP8)="V",SUBSTITUTE(N8:EP8,"V","")+0))

    confirmed with CTRL+SHIFT+ENTER
    Audere est facere

+ 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.2.0