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

clientState not working in daypilot calendar

Asked by Anonymous
12 years ago.

I am trying to get the clientState to work but i am getting the follow-up error:
base {System.SystemException} = {"The JsonData instance has to be initialized first"}

code:
string userId = (string)DayPilotCalendar1.ClientState["userId"];

javascript:
dpc1.clientState = {'userId': 1};

Any ideas ?

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

The clientState value is only synchronized during calls that are coming from the DayPilot control (either PostBack or CallBack).

That means it's not available on the server side when you push a Button or fire another event.

Is that your case?

Comment posted by Anonymous
12 years ago.

I am using the dpc1.commandCallBack function.

Comment posted by Dan Letecky [DayPilot]
12 years ago.

I've tested it with the latest release (6.5) and it seems to work fine.

What's the DayPilot version you are using?

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