Hi Debra,
I entered the code in a module. (Is a sheet module different than a plain
old module? I know class modules are a different beast entirely, and the
code is NOT in one of those.)
To answer your other question, here's how my data is laid out. Column A is
column 1, column I is column 9, and, reading from column A to column I i have
the following column headers: Trans#, Year, Month, Date, Category,
Description, Type, Amount, Balance.
So, column 9 is Balance. That is a formula. The only columns that are NOT
formulas a Amount, Description, and Date. I suppose then that means that
Amount is the last piece of data I enter in a given row. Does that imply
that I should change
If Target.Column < 9 Then GoTo endsub
to
If Target.Column < 8 Then GoTo endsub
Thanks for any insight here.
Dave
--
Brevity is the soul of wit.
"Debra Dalgleish" wrote:
Did you add the code to the sheet module for the source data?
Roger's code refreshes the pivot table when you select a cell in column
9. Do you enter values in that column, or does it contain formulas, and
you skip past it?
Dave F wrote:
Thanks.
This is the code I have, modified with the sheet name, column number, and
pivot table name. It doesn't seem to automatically refresh the pivot table,
though. Am I missing something here?
Option Explicit
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Application.EnableEvents = False
If Target.Count 1 Then GoTo endsub
If Target.Column < 9 Then GoTo endsub
Sheets("Acct").PivotTables("PivotTable2").PivotCac he.Refresh
endsub:
Application.EnableEvents = True
End Sub
--
Debra Dalgleish
Contextures
http://www.contextures.com/tiptech.html