Private Sub Worksheet_Activate()
PivotTables(1).RefreshTable
With Sheets("TDB S")
.Unprotect Password:="condeordolog"
.EnablePivotTable = True
.PivotTables("TCD").RefreshTable
.PivotTables("TCD1").RefreshTable
.PivotTables("TCD2").RefreshTable
.Protect "condeordolog", userinterfaceonly:=True
End With
End Sub