+ Reply to Thread
Results 1 to 7 of 7

Auto add row Macro

Hybrid View

  1. #1
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Auto add row Macro

    Although you use named ranges they static and not DYNAMIC, thus everytime you add more data the new data falls outside of the named range.

    If you use a dynamic named range, then you should get the results you want.

  2. #2
    Registered User
    Join Date
    08-25-2009
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Auto add row Macro

    I am not familiar with dynamic named ranges. I did some research and tried creating a dynamic named range. I used the formula

    =OFFSET(Results!$A$2,0,0,COUNTA(Results!$A:$A),1)

    in the refers to line. The result ID did not carry down when I pasted a new row. Is there additional steps I am missing? Do I need to do something to the data in "Results ID?"

  3. #3
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Auto add row Macro

    The result ID did not carry down when I pasted a new row. Is there additional steps I am missing? Do I need to do something to the data in "Results ID?"
    You have quite a number of static named ranges in your workbook. Not all of them necessarily need to be a dynamic named range, but . . .

    In each range that is named, if you expect to add data, then all of the static named ranges must be converted into a dynamic named range. Then . . .

    Each formula that uses a named range in one of its arguments must be updated with the new name, unless . . .

    You keep the existing name and just modify the "Refers To:" field to a formula for a dynamic named range.

    The example dynamic named range you gave is a legitimate named range. Did you mean for it to be just one column wide? (last argument in the formula specifies the range is only one column)

    Copy and pasting data into a row does not have any effect on dynamic named range other than to force it to expand down another row.

    HTH,

    Palmetto

  4. #4
    Registered User
    Join Date
    08-25-2009
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Auto add row Macro

    I'm not really understanding how the dynamic ranges work. However, I did try using 1 for the number of columns as well as 18 (which is the total number of columns in my results table). Neither seemed to work

    If I understand right, naming the entire table (or just the column you want to carry down?) as a dynamic range will force it to continue the pattern (1,2,3,...) when a new row is created. Is that correct?

    I'm not sure what my formula is missing.

    In the other tables that reference that "result ID," the result ID is not derived from a formula, it is simply typed in. So I am wondering if those will need to be formulas to update as new results are added.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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