I have the following piece of code and it works great until i finished the project and realized that I have other tables that should not be altered by the below code. I love the code (got it frm here) and so i would just like to add something to it so it starts some place other then the very bottom of the spreadsheet.
is there a way to start the lastrow on row 15000 or something and go up from there? maybe after the word row do something like row + 40,000 so i start near row 20,000?
thanks!
is there a way to start the lastrow on row 15000 or something and go up from there? maybe after the word row do something like row + 40,000 so i start near row 20,000?
Code:
lastrow = ActiveSheet.UsedRange.Row + ActiveSheet.UsedRange.Rows.Count - 1
Range("D6:D" & lastrow & ",L6:L" & lastrow & ",U6:U" & lastrow & ",AD6:AD" & lastrow).NumberFormat = "general"
thanks!