PDA

View Full Version : Static cell



TradeTech
12-28-2021, 03:14 PM
Hi,

I am trying to record pasting the copied data in the first empty cell but the macro is coding the cell number,
how can i make this dynamic.

Thanks

大灰狼1976
12-29-2021, 04:32 AM
Hi TradeTech!

cells(rows.count,"A").end(3).offset(1)
Represents the first empty cell in column A

Bob Phillips
12-29-2021, 12:08 PM
Hi TradeTech!

cells(rows.count,"A").end(3).offset(1)
Represents the first empty cell in column A

Not necessarily, it is the blank cell beyond the last populated cell in column A, there could be blank cells in column A between A1 and the last populated cell.

And why would you use End(3) rather than End(xlUp), don't you like making the code clearer?

大灰狼1976
12-30-2021, 08:29 PM
Not necessarily, it is the blank cell beyond the last populated cell in column A, there could be blank cells in column A between A1 and the last populated cell.

And why would you use End(3) rather than End(xlUp), don't you like making the code clearer?
Hello Bob! Thanks for your suggestions. The supplementary explanation is very correct.