VBA Forms

  • Thread starter Thread starter sjenks183
  • Start date Start date
S

sjenks183

I am a beginner/self-teaching VBA user and I would like to know what
"ActiveCell.Offset(0, 1)" code stands for...especially the 0 and the 1.
I believe it has to do with the columns but I am not sure.

Thanks.
 
As you rightly surmise, the 0 and 1 refer to then number of rows and columns
offset from the range being referred to. So in this case, it refers to the
cell that is 0 rows down (negative for up), and 1 column to the right
(negative for left) of the activecell. It doesn't have to be ACtivecell,
this is just as valid

Range("A1").Offset(0, 1)

although this is always A1, whereas Activecell could be any cell.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top