"Code Page" ??

  • Thread starter Thread starter (PeteCresswell)
  • Start date Start date
P

(PeteCresswell)

I'm trying to put in some "AfterUpdate" processing.

Something I Googled advises:

"All you need to do is select the code page for the worksheet in
question, select the drop down at the top left (which should say
'(general)'), pick 'Worksheet' then select the 'Change' member of
the drop down on the right. This will give you the Event sub."

But how to find the "Code page for the worksheet"?

Otherwise, it sounds like the MS Access development environment.

All I see is Tools|Macros - which will get me to a code window,
but that code window lacks the drop down at the top left that
lets me point to "General" or various control names.

What am I missing?
 
On the left side of the code pane [(Use Alt + F11) from your workbook - If
the code pane is not visible - use View from VBA menu -->Project Explorer]
you will find your workbook project - for example, VBAProject (Book1)-->
Below that you will find Microsoft Excel Objects --> Sheet1, Sheet2 etc.

Just double click the Sheet1, which will open the code page for the
correspondig sheet

Here you need to select Worksheet in the first dropdown and the
corresponding event in the next dropdown

If you are looking for workbook event, then you should do the same (double
click on the ThisWorkbook in the project explorer)

Cheers
Shasur
 
Per Shasur:
[(Use Alt + F11) from your workbook - If
the code pane is not visible - use View from VBA menu -->Project Explorer]
you will find your workbook project - for example, VBAProject (Book1)-->
Below that you will find Microsoft Excel Objects --> Sheet1, Sheet2 etc.

Thanks Shasur, Mike, Chip - I'm on the path to enlightenment
now....

At the risk of turning into a tarbaby on you...

Given that I'm in Worksheet_Change() and I have access to
Target.Address - and the worksheet is *not* using R1C1 notation -
how would I go about identifying various cells relative to
Target.Address.

My immediate interest is in clearing the cell immediately to the
right.

I'm working though a multi-column Validation example where the
validation of column B changes depending on what was selected in
column A - so, in the real world, it would seem necessary to
clear the contents of column B if the user changes column A -
since a different list would then be in effect.

If I were in R1C1 notation, I'd parse Target.Address into R and
C, and then increment C or R depending on where I wanted to go.
 

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

Back
Top