![]() |
Offset Question
Hi
have the following line in a macro, but now need it to go to column "A" all the time to pick up some data, how do I force it to a specific column, but stay on the same row? Just to confirm the "rng.Address" could be anything from column B ~ X Range(rng.Address).Offset(rowoffset:=0, Columnoffset:=2).Activate |
Offset Question
Range("A" & activecell.row()).select
HTH Giz "Craig McK" wrote: Hi have the following line in a macro, but now need it to go to column "A" all the time to pick up some data, how do I force it to a specific column, but stay on the same row? Just to confirm the "rng.Address" could be anything from column B ~ X Range(rng.Address).Offset(rowoffset:=0, Columnoffset:=2).Activate |
Offset Question
Here are a couple of ways:
rng.entirerow.cells(1).activate or cells(rng.row,1).activate If rng is on the activesheet, then there's no reason to use range(rng.address). Craig McK wrote: Hi have the following line in a macro, but now need it to go to column "A" all the time to pick up some data, how do I force it to a specific column, but stay on the same row? Just to confirm the "rng.Address" could be anything from column B ~ X Range(rng.Address).Offset(rowoffset:=0, Columnoffset:=2).Activate -- Dave Peterson |
All times are GMT +1. The time now is 10:22 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com