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

DayPilotPro 5.1 Javascript e.start localization problem

Asked by NeokGlitch
11 years ago.

The e.start and e.endis now in local format in 5.1

Wenn i use:
<DayPilot:MenuItem Action="JavaScript" JavaScript="alert('Start: ' + e.start.toString() + '\nEnd: ' + e.end.toString() + '\nResource id: ' + e.resource);"
Text="Show selection details" />

I get this:
www.koenrijpstra.nl/bug.png

And it used to be this:
www.koenrijpstra.nl/bug2.png

How do i fix this?

Comment posted by Dan Letecky
11 years ago.

The e.start() and e.end() functions are now returning the new DayPilot.Date object.

It's a wrapper object that removes the time zone information from the date and adds some useful functions.

For documentation, see www.daypilot.org/daypilot-date-object.html.

You can get the underlying Date object using e.start().d (then you will have the same object as before 5.1).

Comment posted by NeokGlitch
11 years ago.

Thnx it works.

but without the ()

e.start.d

Comment posted by Dan Letecky
11 years ago.

Sorry. Yes, you are correct. e.start is for time-range-related events, e.start() is for event-related events.

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