97 to 2000 Refresh pivot table

D

Deeds

I wrote code for a button that refreshes a pivottable on click. When I try to click the button using 97 I get a Run Time Error. Can someone please tell me how to use the Activesheet.RefreshPivotTable code so that it works in both 2000 & 97
Thanks
 
D

Debra Dalgleish

Set the command button's TakeFocusOnClick to False, or add the following
line at the beginning of the code:

ActiveCell.Select
 
Top