search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

Prevent resetting to top of scheduler after saving?

Asked by Rob Edwards
9 years ago.

When a user adds a new item to the scheduler the scheduler resets back to the top of the vertical scroll area.

For example, say you have so many resources that the scheduler scrolls vertically. You scroll down to an area normally not visible, right click the scheduler and add a new item. Once posted back via ajax and the scheduler data refreshed to reload the data, the scheduler is now at the top of the scroll area again. The user has to scroll back down to see the item they just added.

Is there something i can do to set it so it stays in place?

Answer posted by Dan Letecky [DayPilot]
9 years ago.

In most cases, it should not reset (at least it is not reset explicitly).

However, you can save the vertical scrollbar position before the AJAX call using getScrollY() and set it to the same value after update using setScrollY():

http://api.daypilot.org/daypilot-scheduler-getscrolly/
http://api.daypilot.org/daypilot-scheduler-setscrolly/

This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.