I'm trying to use VBA (novice!) to update a range of data, and I need to find the end of that range and then paste in new data. I'm currently selecting cell A1, moving to the bottom of that range, then trying to move one more cell down to get out of the filled-in area. Here's my code:
This selects the filled-in range, but then deselects the range and moves the cursor down to cell A2, so I'll end up pasting data on top of existing values.
I'm sure I'm doing it wrong, but I can't find a good way to identify the range of rows that are filled in so that I can select the first empty row.
Any help you can offer would be most appreciated!
Code:
Range("A1").Select
Range(ActiveCell, ActiveCell.End(xlDown)).Select
ActiveCell.Offset(1).Select
This selects the filled-in range, but then deselects the range and moves the cursor down to cell A2, so I'll end up pasting data on top of existing values.
I'm sure I'm doing it wrong, but I can't find a good way to identify the range of rows that are filled in so that I can select the first empty row.
Any help you can offer would be most appreciated!