Posts

Showing posts from December, 2014

The Managed Metadata Service or Connection is currently not available. The Application Pool or Managed Metadata Web Service may not have been started. Please Contact your Administrator.

After some searching, I will fix the issue: ·          Backup database of Managed Metadata service ·          Delete the existing Managed Metadata service application (without deleting the database) ·          Create a new Managed Metadata service application with new database ·          Edit the properties of the new Managed Metadata service application, point to the original database (if new managed metadata service is not working) ·          Iisreset (if needed)

Successfully launched “PROVIDER HOSTED APP” in MICROSOFT OFFICE STORE

I have successfully completed and deployed "Provider Hosted App" in Office Store. My App available in the Office store now HAPPPPPPPPPPPPPPPPPPPPPPPPPYYYYYYYYYYYYYYYYYYYY

Adding HTML page Content into SharePoint Page(.aspx) / Showing HTML content in SharePoint page(.aspx)

Requirement: Read HTML file from SharePoint document library and show it inside the SharePoint page (.aspx)(Read all html files and show into custom webpart, Onclicking the document link it should redirect to custom page where we will display the HTML file). i tried the below code to display to HTML content inside the SharePoint page (.aspx) C# StreamReader srHTML = null ; string strHTML = string .Empty; SPFile spfile = SPContext .Current.Web.Lists.TryGetList( "Documents" ).GetItemById(45).File; srHTML = new StreamReader (spfile.OpenBinaryStream()); strHTML = srHTML.ReadToEnd(); srHTML.Close();            ltrHTMLContent.Text = strHTML; asp.net < Div style =" height : 500px">         < asp : Literal ID ="ltrHTMLContent" runat ="server"></ asp : Literal > </ Div > The above is working very perfect.  Happy coding. I hope this will helps you....

SharePoint 2013: Adding a Blog to an Existing Site (without creating a new blog site)

Image
use the below PowerShell cmdlets Enable-SPFeature -identity "BlogContent" -url  "Sitecollection URL" After enabling the feature go to “Site contents“ then you will find 3 lists named “Posts”,”Comments” and “Categories”. Then u just navigate ‘Posts’ list and click an item then u will get the blogs UI

Install WSP in SharePoint using Powershell

WSP Installation Guide To add a wsp package Add -SPSolution "<WSP full path>"  e.g.:  Add -SPSolution "C:\kannan.wsp" To install wsp package Install-SPSolution –Identity "<wsp name>" –WebApplication "<Site collection URL>" –GACDeployment  e.g.:  Install-SPSolution –Identity "kannan.wsp" –WebApplication http://servername:1000   –GACDeployment  Activate the Feature Enable-SPFeature FeatureFolderName –url “site collection URL” e.g.: Enable-SPFeature “ kannan” –url http://servername:1000 --Kannan K

Sharepoint 2013 Distributed Cache cacheHostInfo null

Today i had one problem while start the Distributed Cache in SharePoint 2013 i was getting the below error cacheHostInfo is null After that i found the below PowerShell cmdlets to resolve this issue I ran the below cmdlet to find the GUID in the ID section of the Distributed Cache Service that is causing an issue Get-SPServiceInstance after that i ran the below cmdlet $s = get-spserviceinstance  f40a881c-buc2-4e8b-a846-172fd835e785 $s.delete() before do this make sure that "AppFabric Caching Service" service should be disabled

SHAREPOINT 2013 – DISTRIBUTED CACHE AND NEWSFEED QUESTIONS & ANSWERS

Can the cache be interrogated to obtain names of users that have posted and details of data? The cache cannot be interrogated to obtain names of users that have posted and other details of the data. Are one Distributed Cache hosts the main one and the other a standby or do both serve feeds? Both the Distributed Cache Servers serve feeds. It is for load balancing purpose and not for high-availability. What happens if one host goes down or is rebooted without warning? Will I lose feeds? The feeds will not be lost, they are stored in the database. Is this issue due to using dedicated mode opposed to collocated? When a new post is created, the content of that post is added to a profile property called  SPS-StatusNotes  to the Microfeed list on the user’s Mysite and then to the Distributed Cache. What is the best way to view new posts successfully added? Use SQL Profiler trace which reveals that SharePoint updates the  SPS-StatusNotes  property using a Stored Procedure called  dbo.pro

How are NewsFeeds Created and Stored in Sharepoint 2013

How are NewsFeeds Created and Stored in Sharepoint 2013 In SharePoint Server 2013, the newsfeed (or just simply the feed) displays activity information to users. Users access the feeds from a user's My Site. In SharePoint Server 2013, a user's My Site has several feeds available from which to choose. These different feeds show different views of activity information by filtering or pivoting on activity metadata. The different feeds available to users from their My Sites include the following: Newsfeed     Everyone     Activities     Mentions     Likes     How are Feeds Created -   All Activities are written to the Distributed Cache.The microblog features and feeds rely on the Distributed Cache to store data for very fast retrieval across all entities. Feeds mainly Rely on the following two Caches from Distributed Cache service. " Feed Cache"  that Stores recent activities and recent conversations for all entities " Last Modified Time Cache"

Programmatically LIKE and UNLIKE a SharePoint List Item

Before do this, Ensure "Likes" is enabled in " Rating Settings " under " List Settings " There are two ways to like and Unlike an Item 1. Reputation Class Reputation.SetLike(ListID,ItemID,true); If you want to unlike an item u need to write the below code Reputation.SetLike(ListID,ItemID,false); 2. Directly updating the List fields SPFieldUserValueCollection likedBy = new SPFieldUserValueCollection(web, item["LikedBy"].ToString());  SPUser user = web.EnsureUser("UserName"); SPFieldUserValue newUser = new SPFieldUserValue(web, user.ID, user.Name);  likedBy.Add(newUser); int likes = likedBy.Distinct().Count(); item["LikesCount"] = likes; item["LikedBy"] = likedBy; item.SystemUpdate(false);