Synchronising 2 schedulers on the same page

I have 2 scheduler objects on the same page which show the same information but in different ways using different unit views.

What I want to do is synchronise the vertical postion in both schedulers so when the user scrolls down in one scheduler I want the other scheduler to mirror the vertical position.

Is there an easy way to access the scroll bar object position and/or events which fire when this is changed?

Thanks.

Actually scheduler was coded in such way , so only one instance per page can work correctly. I’m not quite sure how you are able to have few working instances on the same page.

Is there an easy way to access the scroll bar object position

var top = scheduler._els["dhx_cal_data"].scrollTop;
//or
dhtmlxEvent(scheduler._els["dhx_cal_data"],"scroll",function(){
   do_some_on_scroll();
});

Both snippets need to be used after scheduler.init

Thanks for the reply.

I was probably misleading you there slightly. Each scheduler is within its own iframe, so it is actually 1 per page.

Thanks.

Where or how does the event need to be declared? Before or after scheduler.init?

Declaring it before seems to cause an error, after doesn’t work.

After scheduler.init and it must look as

dhtmlxEvent(scheduler._els["dhx_cal_data"][0],"scroll",function(){
   do_some_on_scroll();
});

The previous one was incorrect, sorry for inconvenience

Worked like a charm cheers.