SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using the SharePoint 2013 Client Library and am trying to generate new wiki articles.

I'm able to connect, retrieve the web, find the list, but I can't add items. I feel like I need to be using Microsoft.SharePoint.Client.Publishing, since I am really trying to create a publishing page, but I'm not sure how to go about this.

ClientContext context = new ClientContext("");
List list = context.Web.Lists.GetByTitle("Documentation");


ListItemCreationInformation itemCreateInfo = new ListItemCreationInformation();
ListItem newItem = list.AddItem(itemCreateInfo);
newItem["Title"] = "Peter API Test 1";
newItem["Page Content"] = "Hello World!";

context.ExecuteQuery(); //errors saying Title is not a valid column name...

Any guidance would be greatly appreciated.

share|improve this question
up vote 3 down vote accepted

I found a working example at This example worked on the first try without issue.

share|improve this answer
Hehe, thanks Peter. SP2010 is quite challenging to crack. SP2013 is much better, however some of the areas are still not covered. I'd also would recommend to check out SPMeta2 library to get more insights and code samples. – avishnyakov Jun 14 '13 at 9:46

Well the quick stuff first:

A Wiki Page is NOT a publishing page, so you are probably not trying to create a publishing page..


"Page Content" is not an internal name of a SharePoint field / column. They do not contain white space, the actual internal name is "WikiField"

Not sure why it tells you that "Title" is invalid though! But I would guess it is because a field with that internal name does not exist in the list "Documentation"

share|improve this answer
Do I need to specify the content type so that it will know which columns are available? – Peter Jun 13 '13 at 13:47
Could be, sorry but I'm not an expert on Client object model. I just spotted some errors when glancing through your code that I wanted to point out before you had to spot them yourself! – Robert Lindgren Jun 13 '13 at 13:49
Oh, but look what I found!… – Robert Lindgren Jun 13 '13 at 13:51
I tried that code, but it kept throwing errors. I found another example though that worked first try. – Peter Jun 13 '13 at 14:27
Just to note: as @KevinMcKeown has pointed out below, a Wiki page does not have a title. – Michael Coxon Jun 23 '15 at 11:42

If you look at the content type for a Wiki Page, or at the default columns list in Library Settings for the Wiki Page library, you will notice that "Title" is not an available column. This may be causing you problems. It also causes an error in SharePoint 2013 when you try to click the "Shared With" ribbon button for a wiki page item.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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