10-27-2020 08:58
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-27-2020 08:58
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I have a view that needs to have some values updated after the view gets re-loaded after a Swipe Back event. When the page is re-loaded its 'start' or 'upload' functions are never called so I can't update any values. When a view is re-loaded via the Swipe Back event, is there a way to force a function call? Or is there something like a 'onReload' event that I can attach an EventListener to?
Answered! Go to the Best Answer.

Accepted Solutions
11-16-2020 05:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


11-16-2020 05:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
You should be able to capture the beforeunload event, then call your other functions.
https://dev.fitbit.com/blog/2020-09-24-announcing-fitbit-os-sdk-5.0/#swipe-back

11-16-2020 05:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


11-16-2020 05:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
You should be able to capture the beforeunload event, then call your other functions.
https://dev.fitbit.com/blog/2020-09-24-announcing-fitbit-os-sdk-5.0/#swipe-back

10-26-2021 23:14
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


10-26-2021 23:14
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hi, @DanMacLeod - Did you master this? After the beforeunload is triggered and preventdefault issued the screen blanks. Is there a way just to ignore the Swipe back and continue without the need for animate?
In other words can you carry on as if the swipe back has not been performed without reloading the app.
Author | ch, passion for improvement.

11-03-2021 08:21
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


11-03-2021 08:21
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I'm trying to stay on the same display/view rather than unloading the App when a swipe to the right is performed - is this possible?
Author | ch, passion for improvement.

