Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I'm new to QW and trying to build an application that will store two chosen years in two different variables that can check the variance between them.
I have set up two different input boxes with the variables vYear1 and vYear2. I have set up a choose in field trigger for the vYear1:
='>=' & vYear1 & '<=' & vYear1, and the same for vYear2: ='>=' & vYear2 & '<=' & vYear2. i've also created two straight lists that are suposed to return Sum($(vYear1)Cost) and Sum($(vYear2)Cost). I also have a variance straight list and i want it to return Sum({<$(vYear2)>} Cost) - Sum({<$(vYear1)>} Cost).
the problem is when i set the value in the input box both the variables in the straight lists gets effected and and i can't select more then one year every time a put in a new value in the input boxes. I cant get the Variance straight list to work either, i think it's because both variables are reading the same year but i don't know how to fix it.
I've attached a sample file with the qwv and the xlsx were i load the data from.
Help, guidance and suggestions will be much appreciated!
Try expressions like this: Sum({<Year={$(vYear2)}>} Cost) - Sum({<Year={$(vYear1)}>} Cost)
Try expressions like this: Sum({<Year={$(vYear2)}>} Cost) - Sum({<Year={$(vYear1)}>} Cost)
still returned 0. think the problem lies in the variable. Both variables sums the same year and subtracts the same value
Make sure to use both variables. This will always return zero: Sum({<Year={$(vYear1)}>} Cost) - Sum({<Year={$(vYear1)}>} Cost)
both variables are beeing used. The thing is when i use the input boxes, both variables read from the the box where i made the latest entry. I need the varibles to read from the input boxes separately to make it work.
I have no idea what you mean. Your example qvw file works fine after fixing the expressions.
Oh whatch the wrong application:P Thank you!!