|2 comments on this line of your code:|
Range("C65536") is the "old school" syntax from Excel versions prior to 2007.
Since 2007 and beyond can have more than 65536 rows, the following syntax should be used for all versions, making the code a bit more portable:
Range("C" & Rows.Count)
You are also Selecting a cell with that line.
Rarely do you have to Select an object in VBA, and doing so makes the code inefficient. It is more efficient to perform your actions on the object within VBA itself instead of have Excel Select the object first.
The same goal can be accomplished as follows:
Set LRange = Sheets("Sheet1").Range(Range("C" & Rows.Count).End(xlUp).Address)
Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.