How to get swipe event in FlipView(C#)


  • As title, I want to  know the time when user is swiping page, I have tried the manipulation event,but that will block the Flipview.

    Any suggestion would be appreciated.



    Thursday, September 13, 2012 11:25 AM

All replies

  • Hi Angie,

    What is the scenario you are trying to achieve? There may be a better way than trying to have two objects (yours and the FlipView) both trying to handle the same gestures.


    Friday, September 14, 2012 3:40 AM
  • Hi Rob,

    I want to create a gallery that can play video file.

     In flipview , user would first see the video thumbnail, and tapping the page to start playing video

    ,then when user start swiping to leave,the cuurent media element that plays the video would be collapsed and show the video thumbnail again.

    Since the media element is out of the flipview, I need to immediately collapse the media element when userr start swiping.

    If there are any better ways,please let me know.



    • Edited by Angie_H Friday, September 14, 2012 5:16 AM
    Friday, September 14, 2012 5:15 AM
  • I'd take a look at the SelectionChanged event. The problem with trying to detect the start of a swipe is that the user might not complete it.


    Monday, September 17, 2012 3:42 AM
  • Yes, SelectionChanged  is not the event I want, the event would not fire immediately when user start swiping.

    Please let me know if you have found any solution.



    Tuesday, September 18, 2012 7:31 AM
  • I am interested in this problem as well.

    In my case, I don't want to generate the content for every possible page immediately. Instead, I create the pages on the fly for the current page plus nearby ones. The problem is when a user starts swiping repeatedly without letting the FlipView settle, I can't get any feedback that this is happening, and so my app will have to wait for the whole thing to settle before updating. This isn't just a problem for the rendering of the content, but for other parts of my app that are dependent on which page I'm currently viewing. While it sort of works right now, it's kind of clumsy.

    This also seems like a problem that Angie might run into. If there's, for example 10 pages and the user starts swiping rapidly, the video won't close until the user finally settles on a page, possibly quite a while later.



    Wednesday, November 28, 2012 10:55 PM
  • If I understood you correctly, the MediaElement is on top of the FlipView but not in the FlipView. You can look into those two events ManipulationStarting and ManipulationStarted. Alternatively, you might set the IsHitTestVisible property of the MediaElement to False at which point the FlipView would be the recipient of the manipulation.


    Thursday, November 29, 2012 3:16 AM