Issue
In SharePoint Online (haven’t tested with on-premise), when creating new Group Calendar, the created calendar list doesn’t include the required Schedule content type.
Steps to reproduce
1. Start to create new list, select Calendar, and click More Options button
2. Input Name for the calendar, and in the Group Calendar Options, select Yes to make this calendar a group calendar. Then click Create button at the bottom.
3. Start to create new event in the calendar and you will note that the Content Type used is incorrect.
4. Go to List settings of this new list and you will see that there is only Event content type defined.
Solution
Reason for this is that when you define a calendar as a Group Calendar at the time of calendar creation, it will not include the required content type called Schedule. In order to get the Schedule content type visible, do this:
1. In List Settings screen of your new group calendar, select “Title, description and navigation”
2. Set Use this calendar to share member’s schedule to No, and click Save
3. Go back to “Title, description and navigation”
4. Set Use this calendar to share member’s schedule to Yes, and click Save
5. TADAA! The missing Schedule content type is now visible and you’re good to go!
Can v do it programmatically using Client object model or webservices of sharepoint.. if so.. how?
ReplyDeleteUsing Client OM:
ReplyDeleteClientContext clientContext = new ClientContext("");
ContentTypeCollection cts = clientContext.Web.AvailableContentTypes; ContentType ct = cts.GetById("0xmyUID");
ListCollection listCollection = clientContext.Web.Lists; IEnumerable docLibLists = clientContext.LoadQuery( listCollection . Where(list => !list.Hidden && list.BaseType == BaseType.DocumentLibrary)); clientContext.ExecuteQuery(); foreach (var list in docLibLists) { list.ContentTypes.AddExistingContentType(ct); list.Update(); } clientContext.ExecuteQuery();
Is there any way to set
ReplyDelete"Use this calendar to share member’s schedule to Yes"
in Client object model. I tried using list.asmx, the Updatelist() method supports only a few ListProperties.
I need to set "EnablePeopleSelector" property to True for achieving quoted
Scenario.
can v able to change tat property using client OM or webservices