You can read the ID of the master event (that one that defines the series) using e.RecurrentMasterId. If you don't define any exception from the rule just delete the record with this ID.
protected void DayPilotScheduler1_EventMenuClick(object sender, DayPilot.Web.Ui.Events.EventMenuClickEventArgs e)
{
switch (e.Command)
{
case "DeleteSeries":
Db.DeleteEvent(e.RecurrentMasterId);
break;
}
setDataSourceAndBind();
DayPilotScheduler1.Update();
}
Replace Db.DeleteEvent() with your own data access layer implementation.
If you allow users to define exceptions from the rule (e.g. this week the meeting starts at 3pm instead of 4pm as defined in the master) then you might want to delete these exceptions as well (each exception has its own record in the database).
If you don't store the master id with the exception record you can find these records using the recurrence field (DataRecurrenceField): All exceptions related to the same master event will use the recurrence field that starts with a prefix derived from the master ID:
string prefix = RecurrenceRule.Prefix(e.RecurrenceMasterId);
Then you simple delete all records where the DataRecurrenceField starts with this prefix. Something like this:
DayPilotScheduler1.DataRecurrenceField="recurrence_info"; // you store the recurrence string in "recurrence_info" db field
...
string prefix = RecurrenceRule.Prefix(e.RecurrenceMasterId);
string cmd = "DELETE FROM events WHERE recurrence_info LIKE '" + prefix "%'";
// ...