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 have the following code:

XmlNode newItemRes = ceoList.GetListItems("Pages", null, getItem, ndViewFields, null, null, null);
XDocument d = XDocument.Load(new XmlNodeReader(newItemRes));
XNamespace ns = "#RowsetSchema";
string newItemId = (from x in d.Descendants(ns + "row")
                 orderby x.Attribute("ows_Created_x0020_Date")
                 select (string)x.Attribute("ows_ID")).First();

newFolderXml = String.Format(
                        @"<Batch OnError='Continue'>
                            <Method ID='1' Cmd='Update'>
                                <Field Name='ID'>" + newItemId + @"</Field>
                                <Field Name='PublishingPageContent'>{0}</Field>
                                <Field Name='Title'>{1}</Field>
                                <Field Name='TaxKeywordTaxHTField'>28;Friday Memo|938edce3-67fd-438e-9c45-f475ab846187</Field>
                                 SPEncode.HtmlEncode(String.Format(htmlBase, title, quickLinks, newPageContent)),
                                 "Friday Memo for " + nextFriday.ToString("M/d/yyyy"));

xd = new XmlDocument();
newItem = xd.DocumentElement;
createdItem = ceoList.UpdateListItems("Pages", newItem);

When I look at the value in newItemId it is the ID of the list item I need to update, but for some reason after I execute this code the page is not updated. Can anyone see what I am doing wrong here?

share|improve this question
up vote 1 down vote accepted


bool test = ceoList.CheckOutFile("http://sp-pubdev:88/" + newUrl, "false", "");

before the code above (I was using true fore the second parameter before) fixed this issue.

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.