+ Reply to Thread
Results 1 to 5 of 5

Copying COUNTIF across Columns but range changing incrementally

  1. #1
    Registered User
    Join Date
    03-02-2016
    Location
    Auckland, New Zealand
    MS-Off Ver
    2016
    Posts
    2

    Copying COUNTIF across Columns but range changing incrementally

    Hi All

    I am trying to use the COUNTIF function to return the number of times a name appears in a range of data that is entered by day and total that number by week. I can get that to work as =+(COUNTIF(Sheet1!C$5:I$57,$A4) but i want to report the same info for the next week range of 7 days which is J$5:P$57 in the next column along, when i drag the formula it automatically chooses the range of D$5:J$57. I've tried manually entering two columns to see if Excel learns and drags across accordingly but it doesn't. Any Ideas?

  2. #2
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,542

    Re: Copying COUNTIF across Columns but range changing incrementally

    Welcome to Excel Forum.
    I think that excel can learn to do this:
    Please Login or Register  to view this content.
    Let me know if you have any questions.
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

  3. #3
    Registered User
    Join Date
    03-02-2016
    Location
    Auckland, New Zealand
    MS-Off Ver
    2016
    Posts
    2

    Re: Copying COUNTIF across Columns but range changing incrementally

    Hi

    Thanks for this, i've tried to implement it but i must be making a mistake. can you break it into steps for me so i can understand how to convert it into the formula i need?

    Thanks

  4. #4
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,542

    Re: Copying COUNTIF across Columns but range changing incrementally

    The formula should be pasted into a cell and then dragged to the right. the +7*(COLUMN(A1)-1) part advances the columns by 7 each time so the range goes from C5:I57 in the cell where the formula is pasted to J5:P57 when dragged to the right one cell.
    Here is a file that has the formula applied, perhaps the setup is not matching what was intended in the initial post, however this is what I envisioned:
    Range Change Countifs.xlsx
    I would suggest running the evaluate formula and see if there is anything that stands out as being dysfunctional.
    Let me know if you have any questions.

  5. #5
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Copying COUNTIF across Columns but range changing incrementally

    Similar to JeteMc's
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Dave

+ 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. Copying a changing range from another workbook and pasting it after last column
    By badlydrunkboy in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-24-2014, 09:21 AM
  2. COUNTIF range keeps changing
    By fishcad in forum Excel General
    Replies: 1
    Last Post: 11-01-2012, 04:54 PM
  3. Replies: 0
    Last Post: 09-15-2012, 02:56 AM
  4. [SOLVED] Changing a CountIf Range so it read the end row from a cell
    By Hyflex in forum Excel Programming / VBA / Macros
    Replies: 16
    Last Post: 05-11-2012, 06:51 AM
  5. Replies: 0
    Last Post: 11-15-2007, 02:39 AM
  6. Countif with a changing range
    By Rayo K in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-15-2006, 09:35 AM
  7. [SOLVED] copying changing range
    By Mifty in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-25-2006, 07:35 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