# Trigger by ScrollPosition

**URL:** <https://forums.fusetools.com/t/trigger-by-scrollposition/2870>\
**Category:** How-to Discussions\
**Created:** [April 28, 2015, 2:59pm UTC](https://forums.fusetools.com/t/trigger-by-scrollposition/2870 "2015-04-28T14:59:24Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cristian\_Karmy1](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/cristian_karmy1/32/480_2.png) [@Cristian\_Karmy1](https://forums.fusetools.com/u/Cristian_Karmy1)\
**Post date:** [April 28, 2015, 2:59pm UTC](https://forums.fusetools.com/t/trigger-by-scrollposition/2870/1 "2015-04-28T14:59:24Z")

</div>

How can Trigger my ManualTrigger with the ScrollPosition of a ScrollViewer?

I have something like this but dont work:

```auto
<ManualTrigger ux:Name="MyTrigger">
    <Change Targer="MyScroll.Opacity" Value="1" />
</ManualTrigger>

<ScrollViewer Pointer.Moved="Movement" ux:Name="MyScroll" Opacity="0">

</ScrollViewer>

```

In Uno:

```auto
    void Movement(object sender, PointerMovedArgs args)
    {

     if(MyScroll.ScrollPosition > 100 ){
     MyTrigger.Enable();
     }

    }

```

Is posible to do something like this?

---

<div class="post-metadata">

**Author:** ![Anders\_Lassen](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/anders_lassen/32/522_2.png) [@Anders\_Lassen](https://forums.fusetools.com/u/Anders_Lassen)\
**Post date:** [April 28, 2015, 3:16pm UTC](https://forums.fusetools.com/t/trigger-by-scrollposition/2870/2 "2015-04-28T15:16:15Z")

</div>

Something like this?

```auto
<ScrollViewer>
    <ScrollRange From="100" To="110">
        <Change Target="MyScroll.Opacity" Value="1">
    </ScrollRange>
</ScrollViewer>

```

---

<div class="post-metadata">

**Author:** ![Cristian\_Karmy1](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/cristian_karmy1/32/480_2.png) [@Cristian\_Karmy1](https://forums.fusetools.com/u/Cristian_Karmy1)\
**Post date:** [April 28, 2015, 3:47pm UTC](https://forums.fusetools.com/t/trigger-by-scrollposition/2870/3 "2015-04-28T15:47:32Z")

</div>

Yes but I need to Disable() a WhileEdgeSwiped in Uno. If the ScrollRange is On, How I put in UNO MyTrigger.Disable();?

To be more specific:

With a WhileEdgeSwiped I show a ScrollViewer, but to go back and hide the WhileEdgeSwiped I want that if the ScrollPosition of the ScrollViewer is between -10 and -20 the WhileEdgeSwiped Disable() to hide the ScrollViewer.

Is posible?

---

<div class="post-metadata">

**Author:** ![Cristian\_Karmy1](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/cristian_karmy1/32/480_2.png) [@Cristian\_Karmy1](https://forums.fusetools.com/u/Cristian_Karmy1)\
**Post date:** [April 28, 2015, 5:57pm UTC](https://forums.fusetools.com/t/trigger-by-scrollposition/2870/4 "2015-04-28T17:57:07Z")

</div>

I solved like this!:

```auto
    <ScrollViewer Pointer.Moved="MyPointer" Width="100" WidthUnit="Percent" HeightUnit="Percent" Height="100" >

    <ScrollRange ux:Name="MyScrollRange" Inverse="true" From="-100" To="-60">
         <Change Target="MyTrigger.On" Value="true" />
    </ScrollRange>

    <ManualTrigger ux:Name="MyTrigger" />

    </ScrollViewer>

```

And:

```auto
    void MyPointer(object sender, PointerMovedArgs args)
    {
        if(MyTrigger.On == true ){
         MyWhileEdgeSwiped.Disable();
         MyTrigger.On = false;
         }
    } 

```

i dont know if this is the right way or not…
