I have used this technique in the past. I have created two sliders which works with one variable, I mean one slider contains % of rows to display and other one Count of rows to display. And also used Top & Bottom toggle button to show the top or bottom %/Count of rows. To get this working I have used sorting by expression.
I don’t see any problem with your variable. It also shows that you have included equal to(“=”) at the beginning of the variable. Have you tried to check the variable value in TextBox to see if it changes? It will be good if you can post the QV document... I can look into this issue for you.
Cheers - DV