this does not work in my situation. actually i've already tried this function. that's why i have to use a long dax code. i basically defind these variables and it works 80%. it's just when i select the date slicer, the goal did not change as expected. it became blank. and when i change another slicer, it works. i would love to go with my current solution because it's so close.
this is how it looks like: when i did not select anything in 'View Date', it shows 82679 in indicator which is all data from 2018 and 19 and (31300 which is 2018 data).
but when i select 2019, the perfect situation is indicator 51379 and goal should be 31300, but it shows blank. i really think it's very close to what i want. may just be some slight change. i created two measures for indicator and goal, and they are in my first threshold.