New answers tagged

1

Follow Method that takes a SPWeb object and a SPUser object. SPServiceContext serverContext = SPServiceContext.GetContext(web.Site); UserProfileManager profileManager = new UserProfileManager(serverContext); string userString = user.LoginName.ToString(); UserProfile userProfile = profileManager.GetUserProfile(userString); if (userProfile != null) ...


1

You can use below code snippet to follow a site //GET USER PROFILE MANAGER SPServiceContext serverContext = SPServiceContext.GetContext(siteobject); UserProfileManager profileManager = new UserProfileManager(serverContext); UserProfile profile = profileManager.GetUserProfile(loginName); if (profile != null) { //Social following manager object for the ...


2

Follow button on SharePoint site do have some different behavior for permissions as it is getting it from SQL directly using Application identity Pool. There are some PowerShell commands to be followed after giving the permissions to allow user clicks on Follow button. Please check below article which explains the same issue: Link below SharePoint 2013 ...


0

something like this DateTime dt = DateTime.ParseExact(yourObject.ToString(), "MM/dd/yyyy hh:mm:ss tt", CultureInfo.InvariantCulture); string s = dt.ToString("dd/M/yyyy", CultureInfo.InvariantCulture);



Top 50 recent answers are included