How to get result from slider?

Mac
PsychoPy version: 2021.2.3

Hi all! I am trying to get participant’s result from a slider in the previous routine. I tried get.Rating function but it is not working. My exp looks like this right now: slider + feedback

Slider:
In my_slider routine I have a my_slider1 component

my_slider routine looks like this:

Feedback:
In islider_rating, I have a code and a text

code:
rating = 0 before experiment, and
rating = my_slider1.getRating() in “begin Routine”

Text:

It always shows up 0, which is the value I initialized “rating” with. I am wondering why isn’t rating updated with the real slider rating?
Can some one help me with this issue? Thank you very much!

Best,
Fan

Hello Fan_Bu,

you need to set the Text to set every repeat instead of constant (default).

Best wishes Jens