PivotTable

G

Guest

Hi all,
sorry for my bad englisch . I have questation about pivot table . I want
restrict user to access column with text.If I protect document , refresh not
enable .
why I restrict user ?
thanx marek
 
D

Debra Dalgleish

you can record a macro as you unprotect the sheet, refresh, then
reprotect. In the recorded code, you can add a password, e.g.:

'==========================
Sub RefreshPivot()

ActiveSheet.Unprotect Password:="MyPwd"
ActiveSheet.PivotTables("PivotTable1").PivotCache.Refresh
ActiveSheet.Protect Password:="MyPwd", _
DrawingObjects:=True, Contents:=True, _
Scenarios:=True, AllowUsingPivotTables:=True
End Sub
'=======================

Then, add a "Refresh" button to the worksheet, and assign that macro to
the button.
 

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

Similar Threads

IIS 7 , 2008 R2 and SQL 2008 2
Domain Name 3
WMI 1
DataGrid 9
Win2003 IIS and webforms 1
PivotTable 1
Open to Blank Pivot Table Data (Excel 2007) 2
View Pivot Table Source data as a Data Table 6

Top