Hi ,
I have a custom sharepoint list named "Sample"
It has columns two columns "ProjectType" and "ProjectDesc".
Now , using WCF service I want to bind the column name and ID of the column ID and display them in a dropdownlist.
When I select a column in dropdown then it should display items in that column.
How to do this?
My Code to retive list
---------------------------
List<string> lstProjects = new List<string>();string siteUrl = "http://home-pc:85/";
ClientContext clientContext = new ClientContext(siteUrl);
clientContext.Credentials = new System.Net.NetworkCredential("home", "123");
Web site = clientContext.Web;
//Getting List
List list = site.Lists.GetByTitle("ProjectType");
clientContext.Load(list);
clientContext.ExecuteQuery();
//Getting Column Names
FieldCollection fieldCollection = list.Fields;
clientContext.Load(fieldCollection);
clientContext.ExecuteQuery();
foreach (Field field in fieldCollection)
{
}
asa