Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi there,
I'm having a problem returning a value for my expression below
sum({<TrnMonth={$('vTrnMonthSelected')}>}NetSalesValue)
where TrnMonth is the selection the user makes via a List Box
and vTrnMonthSelected is a variable with the below formula
GetFieldSelections(TrnMonth)
and NetSalesValue is the summed value I want returned.
All I get back is 0.
When I use just $(vTrnMonthSelected) it returns the selections but whenever I run the main sum line, I cannot seem to get it to work.
Any help would be brilliant
Thanks
Use
={$(vTrnMonthSelected)}>} without ' char ... or ={'$(vTrnMonthSelected)'}>}
Hope it helps
Unfortunately still not working with :
sum({<TrnMonth={'$(vTrnMonthSelected)'}>}NetSalesValue)
Yeah I know I could just use the sum(NetSalesValues), I wanted to use the formula though to add some logic and this was the first step in getting the completed formula complete, but alas it still doesn't work
Nope, neither works unfortunately
try this without using variable,
sum({<TrnMonth={"$(=TrnMonth)"}>NetSalesValue)
and for variable create like this:-
vTrnMonthSelected
=(SubField(GetCurrentSelections(),':',-1))
hii sry for late response, try this
THEN,
sum(if(TrnMonth=vTrnMonthSelected,NetSalesValue))
HOPE it helps
Your first expression works, I then add the variable like you show,
But the last expression still doesn't work
Change your variable from "GetFieldSelections(TrnMonth)" to "=GetFieldSelections(TrnMonth)"