+ Reply to Thread
Results 1 to 7 of 7

Count varying number of blank cells between two values in a column

  1. #1
    Registered User
    Join Date
    08-14-2013
    Location
    Pakistan
    MS-Off Ver
    Excel 2016
    Posts
    32

    Count varying number of blank cells between two values in a column

    Hi,
    I need to count the partners in each deal which is represented by date in Column A. The number of partners may vary in each deal as given in Column B. I think it is possible by counting blank cells between two dates but I could not find the help how to do it.

    Sample data is available here:

    https://drive.google.com/open?id=0B-...UJWYzJzNjR5Wms

    Help will be appreciated.

    Regards.
    Last edited by guest2013; 08-19-2017 at 08:20 AM.

  2. #2
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,914

    Re: Count varying number of blank cells between two values in a column

    attach sample excel file
    Samba

    Say thanks to those who have helped you by clicking Add Reputation star.

  3. #3
    Registered User
    Join Date
    08-14-2013
    Location
    Pakistan
    MS-Off Ver
    Excel 2016
    Posts
    32

    Re: Count varying number of blank cells between two values in a column

    Tried several times to attach the file but the attachment icon does not seem to be working, hence the link:

    https://drive.google.com/open?id=0B-...UJWYzJzNjR5Wms
    Last edited by guest2013; 08-19-2017 at 08:19 AM.

  4. #4
    Forum Expert
    Join Date
    05-30-2012
    Location
    The Netherlands
    MS-Off Ver
    Office 365
    Posts
    14,987

    Re: Count varying number of blank cells between two values in a column

    To Attach a File:

    1. Scroll down to the window below your post Additional Options
    2. In the frame Attach Files you will see the button Manage Attachments
    3. Click the button.
    4. A new window will open titled Manage Attachments - Excel Forum.
    5. Click the Browse... button to locate your file for uploading.
    6. This will open a new window File Upload.
    7. Once you have located the file to upload click the Open button. This window will close.
    8. You are now back in the Manage Attachments - Excel Forum window.
    9. Click the Upload button and wait until the file has uploaded.
    10. Close the window and then click Submit.
    Notice my main language is not English.

    I appreciate it, if you reply on my solution.

    If you are satisfied with the solution, please mark the question solved.

    You can add reputation by clicking on the star * add reputation.

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,916

    Re: Count varying number of blank cells between two values in a column

    In C1 copied down:

    =IFNA(IF(A1="","",MATCH(MIN(A2:A$1000),A2:A$1000,0)-1),LOOKUP(2,1/(B2:B$1000<>""),ROW(B2:B$1000))-ROW())

    Make the range as long as it needs to be.
    Last edited by AliGW; 08-19-2017 at 10:08 AM.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  6. #6
    Registered User
    Join Date
    08-14-2013
    Location
    Pakistan
    MS-Off Ver
    Excel 2016
    Posts
    32

    Re: Count varying number of blank cells between two values in a column

    Thank you for the help, Ali. Your initial formula [=IF(A1="","",MATCH(MIN(A2:A$1000),A2:A$1000,0)-1)] worked just as well for me in Excel 2007, though in Excel 2016 it returns error #Name? I'm not sure why.

    Nevertheless, thanks a lot for your time.

  7. #7
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,916

    Re: Count varying number of blank cells between two values in a column

    I am working in Excel 2016, so maybe you copied something incorrectly.

    Glad to have helped.

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Count non blank cells if values in range in another column are between two numbers
    By Perk1961 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-13-2015, 04:01 PM
  2. Count number of consecutive non blank cells in a column macro excel
    By nasim12w in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-03-2015, 06:00 AM
  3. [SOLVED] Need to count all non blank cells in column that meet criteria of two seperaate values
    By tomcoll67 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 08-26-2014, 04:15 PM
  4. Count number of cells in column per month, ignore blank cells
    By lamdl in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-13-2014, 08:50 PM
  5. Selecting non-blank cells in varying ranges in order to COUNT
    By Coexist in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-08-2013, 04:54 AM
  6. [SOLVED] Formula to count number of blank cells for a specific condition in another column
    By Daniel_12 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-30-2013, 07:16 AM
  7. [SOLVED] count number of values where corresponding cells are not blank
    By ea223 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-22-2013, 07:14 PM

Tags for this Thread

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