using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.SharePoint;
namespace CamlQuery
{
class CamlQuery
{
static void Main(string[] args)
{
"string StrQuery ="";
SPSite site = new SPSite(“site”);
SPWeb testWeb = site.AllWebs[“web”];
SPList bdcList = testWeb.Lists[“list”];
SPQuery query = new SPQuery();
query.Query = StrQuery;
SPListItemCollection filteredItems =
bdcList.GetItems(query);
Console.WriteLine(“ available items”,
filteredItems.Count);
foreach (SPListItem item in filteredItems)
{
Console.WriteLine(“Found Order:”,
item[“Order”],
item[“Order: OrderName”]);
}
}
}
}
-Bharath
Friday, March 27, 2009
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment