# Move ScrollPosition in Javascript

**URL:** <https://forums.fusetools.com/t/move-scrollposition-in-javascript/5503>\
**Category:** How-to Discussions\
**Created:** [April 27, 2017, 1:48pm UTC](https://forums.fusetools.com/t/move-scrollposition-in-javascript/5503 "2017-04-27T13:48:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![kevin](https://avatars.discourse-cdn.com/v4/letter/k/2acd7d/32.png) [@kevin](https://forums.fusetools.com/u/kevin)\
**Post date:** [April 27, 2017, 1:48pm UTC](https://forums.fusetools.com/t/move-scrollposition-in-javascript/5503/1 "2017-04-27T13:48:00Z")

</div>

how do i Move ScrollPosition from the current Position in Javascript?

```
  var scrollPos = Observable([0,0]);
  function fiddelWithTheFEEDview(){
    //FEEDScrollView.gotoRelative(0,0);
    //FEEDScrollView.goto(0,0);
  };

  <ScrollView ux:Name="FEEDScrollView" ScrollPosition="{scrollPos}">
  <!-- some data -->
  </ScrollView>

```

all i want to do is call function `fiddelWithTheFEEDview` and move the ScrollPosition form where it is 20 pixels down…

---

<div class="post-metadata">

**Author:** ![Uldis](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/uldis/32/657_2.png) [@Uldis](https://forums.fusetools.com/u/Uldis)\
**Post date:** [April 27, 2017, 2:09pm UTC](https://forums.fusetools.com/t/move-scrollposition-in-javascript/5503/2 "2017-04-27T14:09:04Z")

</div>

Hi Kevin,

from the code you have shown, it seems you are already halfway there. `ScrollView` has a number of very useful member functions, see [the list here](https://www.fusetools.com/docs/fuse/controls/scrollview#section-table-of-contents).

For one, you have the option to scroll to an absolute position using, for example, [ScrollView.goto(0,100)](https://www.fusetools.com/docs/fuse/controls/scrollviewbase/goto__8607b30c).

Two, there’s an option to scroll to a relative position specified by a float in range from 0 to 1 (1 being 100%): [ScrollView.gotoRelative(0,0.5)](https://www.fusetools.com/docs/fuse/controls/scrollviewbase/gotorelative_8607b30c).

And three, there is the `ScrollPosition` UX property, which you might try to use with the help of [UX expressions](https://www.fusetools.com/docs/ux-markup/expressions#functions), specifically the `y()` function, to get the vertical position of another element.

Hope this helps!
