Note:-
Here we are binding the Title Column as well as LookUp Column.
LinqSampleDataContext context = new
LinqSampleDataContext(SPContext.Current.Web.Url);
EntityList<SharePoint2010ConceptsItem> Concept =
context.GetList<SharePoint2010ConceptsItem>("SharePoint 2010
Concepts");
var query = from cs in Concept
where cs.Status.Title.ToString() !=
"Completed"
orderby cs.Id descending
select new
{
cs.Title,
strStatus=cs.Status.Title,
cs.Id
};
sgvConcepts.DataSource = query;
sgvConcepts.DataBind();
Here we are binding the Title Column as well as LookUp Column.
LinqSampleDataContext context = new
LinqSampleDataContext(SPContext.Current.Web.Url);
EntityList<SharePoint2010ConceptsItem> Concept =
context.GetList<SharePoint2010ConceptsItem>("SharePoint 2010
Concepts");
var query = from cs in Concept
where cs.Status.Title.ToString() !=
"Completed"
orderby cs.Id descending
select new
{
cs.Title,
strStatus=cs.Status.Title,
cs.Id
};
sgvConcepts.DataSource = query;
sgvConcepts.DataBind();
No comments:
Post a Comment