View Full Version : Paste special data till last updated row

03-05-2013, 12:44 AM
Hi ,

Thank you very much for continuous support for my previous posts, I require help in tweaking the code.

I have the data in excel where team updates trackers and lot of formulas are put in place, now I want to give option to freeze the data, when they “Freezedata” macro, which they have updated should be copied and paste special values in the same rows, the dependent row would be E7 to (xldown), can anyone help me with tweaking this code

Sub freezedata()
Range(Selection, Selection.End(xlDown)).Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
End Sub

GV Reddy

03-05-2013, 09:06 AM
GV Reddy,

You don't say what is the problem, but, just to clean up your recorded macro:

Sub freezedata()
Dim Rng As Range
Set Rng = Range("E7", Range("E7").End(xlDown))
Rng.PasteSpecial Paste:=xlPasteValues
Range("E7").Select ' For User Convenince
End Sub

03-05-2013, 10:46 AM
Hi Sam,

Sorry for not being clear, I will rephrase it for better understanding.
I have “sheet1” with information from column E to Z whereinwe update the data in daily basis, and I have put formulas in column AA to AZbased on the data which updated in columns E to z.
Now I would like to write a code to select the data based oncolumn E (Range("E7").End(xlDown)), and I would like to select theentire rows (column E to AZ) copy and paste special values there.


03-05-2013, 10:57 AM
GV Reddy,

What criteria to use to select Cell data?

Rng.EntireRow.Copy to prepare for paste

I must go after this post. I will return tomorrow?

Good luck

03-05-2013, 07:32 PM
Thanks Sam,

It works great. I am glad to draw your attention on this.

Once again thank you so much.