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

Event Moving

Asked by Jaycee
6 years ago.

I'm currently allow user to move event by drag and drop, how do I prompt user to confirm on moving the event?

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

You need to handle the EventMove event on the client side:

<DayPilot:DayPilotCalendar ....
  ClientObjectName="dpc"
  EventMoveHandling="JavaScript"
  EventMoveJavaScript="ask(e, newStart, newEnd);"
/>


<script type="text/javascript">
  function ask(e, newStart, newEnd) {
    if (confirm("Do you really want to move this event to the new location?")) {
      dpc.eventMoveCallBack(e, newStart, newEnd);  // invoke the server-side event
    }
  }

</script>
Answer posted by Jaycee
6 years ago.

Thank you. It's working...

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