Hi All,
I have a workbook with several worksheets. I have this one worksheet that has charts and a list box on it. I can get the data to change in the charts after I click the refresh button. I would like to write some VBA code so the charts change after the user changes the items in the list box. I've tried the following code, but it doesn't work. Nothing happens. I've never worked with a Private Sub before. Maybe I'm doing something work or leaving something out.
Private Sub Worksheet_Change(ByVal Target As Range)
Worksheets("Sheet1").PivotTables("PivotTable1").PivotCache.Refresh
End Sub
Bookmarks