# Get and set scroll position of flex repeater with script?

**URL:** <https://forum.inductiveautomation.com/t/get-and-set-scroll-position-of-flex-repeater-with-script/29650>\
**Category:** Ignition Early Access\
**Tags:** perspective\
**Created:** [November 4, 2019, 7:42pm UTC](https://forum.inductiveautomation.com/t/get-and-set-scroll-position-of-flex-repeater-with-script/29650 "2019-11-04T19:42:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![apagrach](https://avatars.discourse-cdn.com/v4/letter/a/3da27b/32.png) [@apagrach](https://forum.inductiveautomation.com/u/apagrach)\
**Post date:** [November 4, 2019, 7:42pm UTC](https://forum.inductiveautomation.com/t/get-and-set-scroll-position-of-flex-repeater-with-script/29650/1 "2019-11-04T19:42:09Z")

</div>

I have a long flex repeater with items that open a new view when clicked. Before the new view is opened is there a way to capture the current scroll position, save it in tag or pass it into the new view as a parameter and then when the user presses a return button to go back to the original view the scroll position is set to the same spot by a script. Please let me know how this can be done or if there is a better way of achieving this functionality. Thanks.

---

<div class="post-metadata">

**Author:** ![kgamble](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kgamble/32/8019_2.png) [@kgamble](https://forum.inductiveautomation.com/u/kgamble)\
**Post date:** [November 4, 2019, 7:59pm UTC](https://forum.inductiveautomation.com/t/get-and-set-scroll-position-of-flex-repeater-with-script/29650/2 "2019-11-04T19:59:54Z")

</div>

Could you open up your secondary view as a popup? Then it would just happen on top of your original repeater and wouldn’t cause the original repeater to change at all.

---

<div class="post-metadata">

**Author:** ![cmallonee](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cmallonee/32/6416_2.png) [@cmallonee](https://forum.inductiveautomation.com/u/cmallonee)\
**Post date:** [November 4, 2019, 8:08pm UTC](https://forum.inductiveautomation.com/t/get-and-set-scroll-position-of-flex-repeater-with-script/29650/3 "2019-11-04T20:08:52Z")

</div>

There is no way to have Perspective scroll any element in any way. As @kgamble recommended, this might be a good spot for a Popup to be used, or possibly an Embedded View. There are several layouts that could conceivably work to prevent you from navigating to a different View, but if navigating to a different View is a requirement then your View which contains the Flex Repeater will be forced through the shutdown/startup lifecycle and will always start at the top of the Flex Repeater again.
