'Scroll To' not working when displaying hidden content with variables

When I set a variable to show a hidden frame of content and then set a ‘Scroll To’ action so that the page scrolls down to this newly visible content, the scroll doesn’t work. If the frame is manually set to display (true) and I click the button, it scrolls down as expected. I placed the ‘Scroll To’ action after the ‘Set to true’ action to make sure the element was displayed before the scroll command was issued but to no avail. Is this a limitation or have I got things wrong?

The ‘Change to’ and ‘Set’ actions are placed in the main component but the ‘Scroll to’ is set at the instance as the main component has no context for the content frame.