Monday, October 19, 2015

How to list ID Custom SharePoint list Using Server Object Model?

Server Object Model:

using(SPSite osite = new SPSite(strURL))
{      
   using(SPWeb oweb = osite.OpenWeb())
   {
      SPList list = oweb.Lists["Workplan"];
string listid=list.ID.ToString();
     string listtitle=list.Title.ToString();
    }          
}

No comments:

Post a Comment