Thursday, 13 March 2014

insert lookup field in sharepoint custom list using c#

 SPSecurity.RunWithElevatedPrivileges(delegate            {                using (SPSite site = new SPSite(SPContext.Current.Site.ID))                {                   ...
Continue Reading...

get all lookup value from sharepoint customlist using c#

 List<string> myCollection = new List<string>();            SPSecurity.RunWithElevatedPrivileges(delegate            {                using (SPSite site = new SPSite(SPContext.Current.Site.ID))               ...
Continue Reading...

Saturday, 1 March 2014

Check the current Login user in sharepoint Group using c#

  SPSecurity.RunWithElevatedPrivileges(delegate()                {                                       SPWeb theSite = SPControl.GetContextWeb(Context);                   ...
Continue Reading...

Convert multiline text to string in sharepoint using c#

The below code is convert the SharePoint customList multiLine text column to string using c#        String description = Convert.ToString(item["Description"]);        SPHttpUtility.ConvertSimpleHtmlToText(description, -1...
Continue Reading...

Checkin-Publish folder in SharePoint using powershell

Add-PSSnapin "Microsoft.SharePoint.PowerShell"### GLOBAL VARS, CHANGE HERE$listname = "Style Library" $url = "http://Abcd:1111/sites/SampleSite/"function approveContent ($w, $listName) {  $list = $w.Lists |? {$_.Title -eq $listName}  foreach ($item in $list.Items)   {    if(($item -ne $null) -and ($item.LockId -ne $null)) {      $item.ReleaseLock($item.LockId)   ...
Continue Reading...

Followers

Follow The Author