Closed Thread
Results 1 to 3 of 3

insert a row every nth row and sum range

  1. #1
    Registered User
    Join Date
    10-08-2007
    Posts
    1

    insert a row every nth row and sum range

    Can anyone help me create a macro that will insert a row every nth row and at the same time sum the values of the cells above it? I have a data sheet that has 240 values per day in three columns. I am looking to separate the days with a row that sums the totals for all three columns for the day. The values are based on 24 hours so I would also like to get a daily average by dividing the sums by 24 but if anyone could help me with just the first part it would be greatly appreciated. I have 25 years worth of data that must be broken down into months and I am working with hourly readings per day --very tedious without programming.
    Thanks, barb

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678
    I would use SUMIF or SUMPRODUCT formulas, and put them _above_ all the data. They're easier to find.

    If you post a sample of your data, I or someone else will show you how.

  3. #3
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    Thread closed for cross posting

    Please read forum rules below. If you agree to them private message me and I will unlock the thread so you can add the link

    VBA Noob
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

Closed 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.6.0 RC 1