cancel
Showing results for 
Search instead for 
Did you mean: 

SAPUI5 List swipe to navigate to another Page

Former Member
0 Kudos

Hi Guys,

I have a list on which when a user swipe from righttoleft I want to navigate to Page A and when he swipe feom lefttoright then I want to navigate to Page B. On the swipe event I am not been able to get the user swipe direction. can some one tell me how to do this.

Thanks and best regards.

fahad

Accepted Solutions (0)

Answers (1)

Answers (1)

surendra_pamidi
Contributor
0 Kudos

Hi Fahad,

Use..

"app.to("page");"        if you are using app in that content.

On swipe, get the item which you selected and according to that  do operations as "app.to("page");"

Or use carousel...

If you want to get more approximate answer, can you provide some sample code or output image....

Former Member
0 Kudos

Hi Surendra,

That's clear but how to get the swap direction (means in which direction the user swapped).

Best regards.

Fahad

surendra_pamidi
Contributor
0 Kudos

Can you show your output.. So that we can help better

Former Member
0 Kudos

Hi Surendra,

Thanks for your reply, really nice of you.

I attached here 2 images so that you can understand the scenario. I have a "Main Page" with a list. When I swipe on the list from Left to Right then I want to go to navigate to "PAGE A" as shown in the following image.

But When I swap on the same Page "Main Page" on list from Right to Left then I want to navigate to a different Page "Page B" as shown in the following image:

The only problem is how to get these 2 different swap directions, How can I know that the user swapped towards left or right so that I can navigate to the appropriate page. I hope it's clear now.

Best regards.

Fahad