Is it possible to use a cell reference in place of country name
"[Data].[Ship-to Country].&[Spain]")
"[Data].[Ship-to Country].&[Spain]")
Code:
Sub SelectCountry()
ActiveSheet.PivotTables("Pt1").PivotFields( _
"[Data].[Ship-to Country].[Ship-to Country]").VisibleItemsList = Array( _
"[Data].[Ship-to Country].&[Spain]")
End Sub