Page 1
Page 1
Started By
Message

Excel Macro Help

Posted on 5/29/19 at 1:43 pm
Posted by KingofZydeco
On da bayou
Member since Jul 2009
1000 posts
Posted on 5/29/19 at 1:43 pm
I'm working on a spreadsheet and I found a macro that copies current day information from and output page ("Data Copy") to the last empty row of a log page ("Historical Data"). This is working well, but I just realized it is copying the info into the log sheet as a reference (not plain text). So everytime I try to enter a new days data the log sheet is changed. What do i need to add to this code to have it copy as plain text to the log page (not the cell reference like it is doing now)?

Thanks!

quote:

Sub CopyRow() Dim lastrowSrc As Long Dim lastrowDest As Long 'Get last row of data lastrowSrc = Sheets("Data Copy").Range("A" & Rows.Count).End(xlUp).Row 'Get first blank row (last row of data +1) lastrowDest = Sheets("Historical Data").Range("A" & Rows.Count).End(xlUp).Row + 1 'Copy row Sheets("Data Copy").Range("A" & lastrowSrc).EntireRow.Copy Sheets("Historical Data").Range("A" & lastrowDest) End Sub
Posted by Brisketeer
Texas
Member since Aug 2013
1437 posts
Posted on 5/29/19 at 2:42 pm to
Instead of the copy, try this:

Sheets("Historical Data").Range("A" & lastrowDest).Value = Sheets("Data Copy").Range("A" & lastrowSrc).Value
Posted by KingofZydeco
On da bayou
Member since Jul 2009
1000 posts
Posted on 5/29/19 at 5:15 pm to
Thanks.... I got it to work!
first pageprev pagePage 1 of 1Next pagelast page
refresh

Back to top
logoFollow TigerDroppings for LSU Football News
Follow us on Twitter, Facebook and Instagram to get the latest updates on LSU Football and Recruiting.

FacebookTwitterInstagram