JQuery操作SharePoint Web Services之删除和更新列表数据
JQuery操作SharePoint Web Services之删除和更新列表数据
这篇文章继续上次的http://www.cnblogs.com/fanwenxuan/archive/2009/12/26/1632998.html操作环境。介绍一下更新和删除列表:
更新列表效果图如下:
删除的代码如下:
var batch =
"<Batch OnError='Continue'> \
<Method ID='1' Cmd='Delete'> \
<Field Name='ID'>"+itemid+"</Field> \
</Method> \
</Batch>";
"<Batch OnError='Continue'> \
<Method ID='1' Cmd='Delete'> \
<Field Name='ID'>"+itemid+"</Field> \
</Method> \
</Batch>";
更新的代码如下:
var batch =
"<Batch OnError='Continue'> \
<Method ID='1' Cmd='Update'> \
<Field Name='ID'>"+itemid+"</Field> \
<Field Name='Title'>"+title+"</Field> \
<Field Name='City'>"+city+"</Field> \
</Method> \
</Batch>";
Powered By D&J (URL:http://www.cnblogs.com/Areas/)