Code: Select all
pPayrollPeriodNumber=114;
MDXRef='{FILTER([Year for Payroll Total].[Year for Payroll Total].MEMBERS ,
([Year for Payroll Total].CURRENTMEMBER.PROPERTIES("Year") = "'|CellGetS('Parameter','Parameter','Payroll year')|'")
AND
#(VAL([Year for Payroll Total].CURRENTMEMBER.PROPERTIES("Number")) <= 114)
(VAL([Year for Payroll Total].CURRENTMEMBER.PROPERTIES("Number")) <= "'|pPayrollPeriodNumber|'")
)}';
SubsetMDXSet(DimNameSource5,SubNameSource,MDXRef);
When I try to change it to work off a parameter it doesn't work. Could someone help with what is needed around the pPayrollPeriodNumber in the (VAL line.
Thanks
Keith