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

Event selecting programatically in DayPilotMonth

Asked by KonstiPisti
11 years ago.

I'd like to modify the event selection from code in DayPilotMonth, but can't find a solution.
This is what I have:

List<DayPilot.Web.Ui.Events.Common.EventInfo> mySelectedEvents = new List<DayPilot.Web.Ui.Events.Common.EventInfo>();

DayPilot.Web.Ui.Events.Common.EventInfo currentEvent = new DayPilot.Web.Ui.Events.Common.EventInfo();

DayPilotMonth1.SelectedEvents = mySelectedEvents;

Problem is, that I Don't have any info on how to create a member of DayPilot.Web.Ui.Events.Common.EventInfo

Does somebody know the solution for this?

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

Since 7.1 SP4 it's possible to create an instance of this class by calling:

  • EventInfo.Create(id) for regular events
  • EventInto.CreateRecurring(masterId, start) for recurring events

This will create an EventInfo stub that holds only the necessary information. The rest of the properties will be filled on the client side automatically (if you add it to SelectedEvents).

http://www.daypilot.org/daypilot-pro-for-asp-net-webforms-7-1-sp4.html

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