detriez
Board Regular
- Joined
- Sep 13, 2011
- Messages
- 193
- Office Version
- 365
- Platform
- Windows
Since I cannot use a formula as report criteria for a Pivot Table I'm trying to set the value to a named range
Dashboard!A1 is my named range = repBrand
I want to push the value of repBrand to the pivot table criteria in IT Detail!D1
Can someone tell me what I'm missing here?
TIA
Dashboard!A1 is my named range = repBrand
I want to push the value of repBrand to the pivot table criteria in IT Detail!D1
Can someone tell me what I'm missing here?
TIA
Code:
Private Sub Testing_Click()
Dim rRange As Range
On Error Resume Next
Set rRange = ThisWorkbook.Names("repBrand").RefersTo
Sheets("IT Detail").Range("D1").Value = rRange.Value
End Sub