Pivot auto refresh

siyat

New Member
Joined
Mar 30, 2011
Messages
48
Hi guys,

I have a issue, i have list that my deparment should write in colum A - B - C and D the data.

in Sheet 1 and in Sheet 2 i got my pivot.

At start when i made the pivot i just changed my range to 5000 since we have only 1000 lines, then i thought it will refresh every time when i press the refresh button in pivot.
It workd 3 4 times and now it stoped working.

Is there any other way to make this work or some easier way.
I try to record a macro but that dosent work and i am very newbie when it comes to VBA.

So i hope one of you experts can help.

Thank you befor hand :stickouttounge:....
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
Hi

download sample workbook from below link
https://rapidshare.com/files/1263785657/AutoRefersh_Pvt.xls


steps
1. Define a Name range on base data sheet
e.g Name Range Define : "=OFFSET(Data!$A$1,0,0,COUNTA(Data!$A:$A),COUNTA(Data!$1:$1))"
2.Go to Create Pivot table
3.in table/Range box enter "Data" which is name range you define eariler
4.select the location for your pivot table & create pivot table
5.right click on sheet1 or sheet2 & paste below code, change your pivot table name accordingly
Code:
Private Sub Worksheet_Activate()
   ActiveSheet.PivotTables("PivotTable1").RefreshTable
End Sub
so whenever your data changes, pivot tables will automatically referesh accordingly when you select respective the sheet
 
Last edited:
Upvote 0
I cant make it work for some reason it works after i save it, it will stop working.
Is there any way i can attach the file and you look at it?
 
Upvote 0

Forum statistics

Threads
1,224,603
Messages
6,179,850
Members
452,948
Latest member
UsmanAli786

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top