+ Reply to Thread
Results 1 to 9 of 9

Macro to Move Visible Cells after Subtotaling

Hybrid View

  1. #1
    Valued Forum Contributor
    Join Date
    03-23-2008
    Location
    Tennessee
    MS-Off Ver
    Office 2007
    Posts
    706

    Perfect!!

    This does exactly what I needed it to do. I will select all columns containing data from B thru G, and then paste only the visible rows into cell A1 on my "Subtotals" worksheet.

    There is no data on my subtotals sheet until the new data is pasted, so I removed the offset function from the end of your statement.

    Thanks fo the help!

  2. #2
    Valued Forum Contributor
    Join Date
    03-23-2008
    Location
    Tennessee
    MS-Off Ver
    Office 2007
    Posts
    706

    Not Quite Perfect...

    Mr. Ice,

    I'm afraid I posted prematurely when I said the code was perfect.

    The code you sent worked nicely when I selected columns A thru G, and then ran the code, except that it pasted the column headings from the data worksheet below the column headings on the subtotals worksheet.

    I thought that by removing the offset, it would just replace the headings, which would be fine. Well, you probably already know, removing the offset ain't the answer.

    I'll play with it until I get it figured out from here.

    Thanks again.

    Jerry

  3. #3
    Valued Forum Contributor
    Join Date
    03-23-2008
    Location
    Tennessee
    MS-Off Ver
    Office 2007
    Posts
    706

    Still Need Help...

    This is frustrating!

    I tried everything I knew to take the cells and simply paste them into cell A1 of the subtotals worksheet, but never could get it to work. Most of my edits simply made it paste the last row of my selected data into cell A1.

    I know this is going to be so simple it will embarass me, but how do I simply select the cells, and have it paste visible cells to cell A1 on subtotals?

    Thanks!

  4. #4
    Valued Forum Contributor
    Join Date
    03-23-2008
    Location
    Tennessee
    MS-Off Ver
    Office 2007
    Posts
    706

    Bump

    I never got a response to the last question, so I thought I'd bump this back up on the list.

    Any help would be appreciated.

    Jerry

  5. #5
    Registered User
    Join Date
    05-02-2006
    Posts
    80
    Hi,

    I'm guessing that you're problem now is that you keep having the column headings copied over from the first worksheet to the subtotals.

    To avoid this modify the beginning of the IF statement so it's as below:

    If Row.Height > 0 And Row.Row <> 1 Then
    This will now ignore the first row of data. (I'm assuming your column headings are in Row 1).

    Hope that helps.

    Tris

+ Reply to 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