Logo 
Search:

Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

Metadata problem

  Asked By: Alberto    Date: Jan 24    Category: Sharepoint    Views: 2001

I am trying to modify attributes of list items using List web service. I am
getting a new error as follows. I searched the web but could not get any useful
information. Can someone through me some light on this.

My code:
============================================================================
MetaDataCopy01.SourceLists.Lists listService = new
MetaDataCopy01.SourceLists.Lists();
listService.Credentials= System.Net.CredentialCache.DefaultCredentials;
string strBatch = "<Method ID='1' Cmd='Update'>" +
"<Field Name='ows_ID'>11</Field>" +
"<Field Name='FileRef'>test.doc</Field></Method>";

XmlDocument xmlDoc = new System.Xml.XmlDocument();
System.Xml.XmlElement elBatch = xmlDoc.CreateElement("Batch");
elBatch.SetAttribute("OnError","Continue");
elBatch.SetAttribute("ListVersion","1");
elBatch.InnerXml = strBatch;

XmlNode ndReturn = listService.UpdateListItems("Document Library", elBatch);
============================================================================
The message I am getting from ndReturn is;
<Results xmlns="http://schemas.microsoft.com/sharepoint/soap/">
<Result ID="1,Update">
<ErrorCode>0x8102000a</ErrorCode>
<ErrorText>Invalid URL Parameter The URL provided contains an invalid Command
or Value. Please check the URL again.</ErrorText>
</Result>
</Results>

Share: 

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on Metadata problem Or get search suggestion and latest updates.




Tagged: