+ Reply to Thread
Results 1 to 7 of 7

VBA - FillDown Formulas based on # of Rows in Column B

  1. #1
    Forum Contributor
    Join Date
    02-11-2009
    Location
    Montclair, NJ
    MS-Off Ver
    Excel 365
    Posts
    236

    VBA - FillDown Formulas based on # of Rows in Column B

    Hello,

    Any help with this is greatly appreciated.

    Sincerely, thank you so much,
    Robert


    I have values in Column B, and formulas in C2:I2, which transpose the values in Column B.

    Before.png


    I currently have a macro that will Filldown the formulas in C2:I2 down to the last Row in Column B.

    After Formula Filldown.png


    Unfortunately, this led to meaningless zero's in my Range that I've been having to remove via another macro, which runs extremely slow.


    The Rows in Column B will ALWAYS be divisible by 4.
    Ideally, I would like to Filldown the formulas in C2:I2 1 quarter of the way down of Column B.

    Could you please write something in VBA that would do this for me?


    So, if Column B has 40 Rows, Filldown Formulas 10 Rows.
    Or, if Column B has 32 Rows, Filldown Formulas 8 Rows.

    Ideally After Filldown number of rows divided by 4.png

    This should remove that horribly slow macro that I'd have to run to get rid of the zeros.
    Attached Files Attached Files
    Last edited by sighlent1; 02-10-2022 at 10:59 PM.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,548

    Re: VBA - FillDown Formulas based on # of Rows in Column B

    You don't necessarily need VBA. You could just adjust your formula.

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Forum Contributor
    Join Date
    02-11-2009
    Location
    Montclair, NJ
    MS-Off Ver
    Excel 365
    Posts
    236

    Re: VBA - FillDown Formulas based on # of Rows in Column B

    This is sooo MUCH FASTER!!


    I think this is the best solution considering my circumstances

    Thank you so much!
    Last edited by sighlent1; 02-10-2022 at 10:59 PM.

  4. #4
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,548

    Re: VBA - FillDown Formulas based on # of Rows in Column B

    You're welcome. Thanks for the rep.

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,548

    Re: VBA - FillDown Formulas based on # of Rows in Column B

    If you need a macro, then maybe this:

    Please Login or Register  to view this content.

  6. #6
    Forum Contributor
    Join Date
    02-11-2009
    Location
    Montclair, NJ
    MS-Off Ver
    Excel 365
    Posts
    236

    Re: VBA - FillDown Formulas based on # of Rows in Column B

    I appreciate this alternative!

    Thank you!!

  7. #7
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,548

    Re: VBA - FillDown Formulas based on # of Rows in Column B

    Not so much an alternative as a quick way of dropping the formulae in.

+ 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] use formulas or power query to add/duplicate linked rows with data based on column
    By loganpmgoa in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-14-2019, 01:46 PM
  2. [SOLVED] Excel 2010-VBA: Trying to create a filldown that is based on the current/active column
    By KAP123 in forum Excel Programming / VBA / Macros
    Replies: 27
    Last Post: 11-09-2016, 03:32 PM
  3. Syntax for filldown based on another rows length and specific filter
    By TheN in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-05-2016, 11:23 AM
  4. [SOLVED] Need Help with Macro, filtering one column, and filldown value to last row of a new column
    By mDevel in forum Excel Programming / VBA / Macros
    Replies: 19
    Last Post: 11-08-2013, 01:04 PM
  5. [SOLVED] Using a FillDown method for a column with filtered rows
    By rdun1 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-30-2013, 05:14 PM
  6. [SOLVED] VBA to Filldown Every Other Column with Formula
    By msawyer in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-29-2013, 02:29 PM
  7. Macro to filldown rows
    By divkar in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-25-2010, 11:13 AM

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