I'm using SPServices to insert items to a list. The code works fine except for, some users see the response below:

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<UpdateListItemsResponse xmlns="http://schemas.microsoft.com/sharepoint/soap/">
<Result ID="1,New">
<ErrorText>The operation failed because an unexpected error occurred. (Result Code: 0x80070005)</ErrorText>

Every user has the same level of permission on the list. Any ideas?


Here is the input data:

<soap:Envelope xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:xsd='http://www.w3.org/2001/XMLSchema' xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/'>
        <UpdateListItems xmlns='http://schemas.microsoft.com/sharepoint/soap/'>
                <Batch OnError='Continue'>
                    <Method ID='1' Cmd='New'>
                        <Field Name='AksiyonPlanim'>test</Field>
                        <Field Name='BitisTarihi'>2011-7-2</Field>
                        <Field Name='Title'>test</Field>
                        <Field Name='Kategori'>test</Field>
                        <Field Name='Vendor'>test</Field>
                        <Field Name='Egitmen'>test</Field>
                        <Field Name='Custom'>1</Field>
                        <Field Name='Tip'>Sınıf</Field>
                        <Field Name='Tarih'>2011-7-1</Field>

Edit2: SPServices Code (SPS Version: 0.5.7)

var val = [["AksiyonPlanim", aksiyon_planim], ["BitisTarihi", f_ftarih], ["Title", egitim], ["Kategori", kategori], ["Vendor", kurum], ["Egitmen", egitmen], ["Custom", 1], ["Tip", tip], ["Tarih", ftarih]];

        operation: "UpdateListItems",
            listName: "Egitimler",
            batchCmd: "New",
            webURL: "/Divizyonlar/IK/LEAD", 
            valuepairs: val,
            completefunc: function (xData, Status) {
                var etd_id = 0;
                $(xData.responseXML).find("[nodeName=z:row]").each(function() {
                    etd_id = $(this).attr("ows_ID");
                if (etd_id)
                    operation: "UpdateListItems",
                        listName: "ETD",
                        batchCmd: "New",
                        webURL: "/Divizyonlar/IK/LEAD", 
                        valuepairs: [["Title", etd_id]],
                        completefunc: function (xData, Status) {
                            $(btn).attr("disabled", "");
                            alert("Eğitiminiz başarıyla eklenmiştir.");
                else {
                    $(btn).attr("disabled", "");

Edit 3:

Strange, users are able to insert new items if I add them to the owners group. Any ideas here? I don't want to give full power to everybody.

  • quite difficult to help without the input message. Alos take a look in the ULS logs.
    – Steve B
    Jul 1 '11 at 13:03
  • Please see the input data in my edited question. Unfortunately, I don't have access to the ULS logs.
    – frbry
    Jul 1 '11 at 14:36

I ran into the same error, similar situation and ran across your post here. Luckily, I was able to figure out the problem and wanted to share, even though this post is quite old :)

In my case, I had a custom persmission level set up and the issue was that the following Site Permission was not checked: Use Remote Interfaces - Use SOAP, Web DAV, or SharePoint Designer interfaces to access the Web site.

If I'm not mistaken, SPServices uses SOAP for UpdateListItems.

Hope this helps!


My guess is that there's an issue with the value you show above for the Tip column ("Sınıf"). Try removing that from the update and see if that solves the problem.

Your dates also aren't in the proper format, assuming that BitisTarihi and Tarih are Date/Time columns.

My suggestion is that you slim down the updates to something which works for the "problem" users and then build back up to identify the issue(s).

p.s. When you say SPServices, do you mean http://spservices.codeplex.com? If so, it's always helpful to see your actual code.

EDIT: It looks like you are using a pretty old version of SPServices. I've made a lot of updates since then, some of which help with encoding the valuepairs data. Best to move to v0.6.2.

Also, you should enclose z:row in quotes (won't help with this issue, but is required with newer versions of jQuery):


p.s. You're welcome!

  • Actually my first action was exactly what you're suggesting. I removed all fields except "AksiyonPlanim", but it didn't solve the problem. I've edited the question so please see the relative SPServices code. (By the way, thank you for this great library)
    – frbry
    Jul 1 '11 at 14:54
  • I switched to 0.6.2 but that also didn't solve the problem. Please see Edit 3, it's more tangible.
    – frbry
    Jul 6 '11 at 14:08
  • 1
    It sounds like it's some sort of permissions issue, then. The Web Services respect the permissions the same way that working in the UI does. You users have to have permission to update the items. If any of the columns are Lookup columns they may also need read access on those items. Jul 7 '11 at 3:35

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.