Dynamic Selector : Appear Message "variable is not defined in the current scope" even if it's defined

Has anyone found a solution to this issue? I am having the same issue.

Screenshot 2023-07-24 at 10.06.28 am