I'm working on "Add to Calendar" feature from my Sharepoint webpart (created using VS2010). If I want to include multiple breakdown appointments (For Ex, one for today between 9.00 a.m - 11 a.m & one for tomorrow between 3.00 p.m - 5.00 p.m), How do I do that?
The following code works for a single appointment. Its creating an additional calendar if I have more that one appointment.
Instead I should be able to update my existing calendar with the multiple appointments.
Could you please assist me how to do this?
Here is part of my code
EventSessions = from eventobj1
where eventobj1.Event.Id == eventid
Appointment _appointment =
editor.Content = session.Event.EventDetails;
_appointment.Subject = session.Title;
_appointment.Description = Server.HtmlDecode(editor.Text);
_appointment.Start = session.DateOfSession.Value;
_appointment.End = dtStart.AddHours(session.SessionDuration.Value);
HttpResponse response = Page.Response;
response.ContentEncoding = Encoding.UTF8;