I have a simple Calendar. I have added an entry to the calendar through C#:

ListItemCreationInformation listCreationInformation = new ListItemCreationInformation();
ListItem oListItem = oList.AddItem(listCreationInformation);
oListItem["Title"] = "IDC Townhall2";
oListItem["Location"] = "WAR Room 9";
oListItem["EventDate"] = new DateTime(2016, 11, 10, 10, 0, 0);
oListItem["EndDate"] = new DateTime(2016, 11, 10, 11, 0, 0);
oListItem["Description"] = "Added item description";
oListItem["EventType"] = 1;
oListItem["UID"] = System.Guid.NewGuid();

The code is using my credentials.

In SharePoint (using the same credentials as the C#), the entry does not appear in the Default Calendar View but does appear in the List View. Editing the entry here and updating the Title causes the entry auto-magically appear in the Calendar view.

Can someone point me in the right direction to get the programmatic entries to appear in the Calendar View.


Try to compare the item (created by c#) and item created manually. Some parameter must be missing. You can try to view all properties by using REST API in browser.

| improve this answer | |
  • Thanks for the ideas. Reviewing the properties in C# showed nothing. I think the clue is in the minimal change required to get things showing. I will definitely try the REST idea, and provide feedback. – Ian Nov 4 '16 at 17:31

Problem and solution identified (if not understood). Get rid of the line:

oListItem["EventType"] = 1;
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.