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

EventMoveJavaScript

Asked by Anonymous
7 years ago.

I have my eventmovehandling set to javascript and I want to pass the ID and newstart date to another page. I tried
EventMoveJavaScript="window.location.href = 'schedule.aspx?ID=' + e.value() + '&newstart=' + e.newstart();"
but it's not working. I have also tried using eventmovehandling set to Callback and doing a response.redirect within the VB but it errors out. Is there anyway to do this?

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

EventMoveJavaScript supports the following variables:

  • e (DayPilot.Event object)
  • newStart (DayPilot.Date object)
  • newEnd (DayPilot.Date object)
  • ctrl (boolean)
  • shift (boolean)

The Scheduler and Calendar also support these:

  • newResource (string)
  • external (boolean)

See also:
https://api.daypilot.org/daypilot-calendar-oneventmove/
https://api.daypilot.org/daypilot-month-oneventmove/
https://api.daypilot.org/daypilot-scheduler-oneventmove/

EventMoveJavaScript is translated to onEventMove client-side event handler. It uses api=1 mode.

If you change your code like this it should work:

EventMoveJavaScript="window.location.href = 'schedule.aspx?ID=' + e.id() + '&newstart=' + newStart" 

Let me know if it didn't help.

Comment posted by Anonymous
7 years ago.

Worked perfectly! Thank you!

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