Pages

Wednesday, December 17, 2014

Scroll to top on Commit or Rollback

Scroll to top on Commit or Rollback

This post is about scrolling to some component on user action. Mostly when user click save or cancel, a message is displayed on top of the page. At the same time, it is required to scroll the page to top and show message to the user... rather user scrolling up to see what happened. 

Implementation is simple : 

1. Need a javascript method to scroll.

2. Next step is just to invoke this javascript method at the end of your commit call.


Enjoy!!