// 首先获取到SPWeb对象web
SPListCollection lists = web.Lists;
SPList scoreList = lists["Score"];
SPList passList = lists["Pass"];
SPQuery query = new SPQuery();
query.Query = "<Where><Geq><FieldRef Name='Score'/>" +
"<Value Type='Number'>60</Value></Geq></Where>";
SPListItemCollection items = scoreList.GetItems(query);
foreach(SPListItem item in items)
{
string title = item["Title"] + "(合格)";
item["Title"] = title;
item.Update();
}
SPListItem newItem = passList.Items.Add();
newItem["Count"] = items.Count;
newItem.Update();
SPListCollection lists = web.Lists;
SPList scoreList = lists["Score"];
SPList passList = lists["Pass"];
SPQuery query = new SPQuery();
query.Query = "<Where><Geq><FieldRef Name='Score'/>" +
"<Value Type='Number'>60</Value></Geq></Where>";
SPListItemCollection items = scoreList.GetItems(query);
foreach(SPListItem item in items)
{
string title = item["Title"] + "(合格)";
item["Title"] = title;
item.Update();
}
SPListItem newItem = passList.Items.Add();
newItem["Count"] = items.Count;
newItem.Update();
0
0
java util 巧用
Ant
WEB文件上传二 (Struts 文件上传)
web文件上传一学习记录 (简单的web浏览器可读文件的上传,servlet 文件上传)
long类型的时间转为n秒前n分钟前n小时前或者日期
各种String类型的时间转long型,long转String
Android 内容提供者(ContentProvider)的简单实用
sql性能优化总结(转)
数据添加到DataTable