Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
We used to get IContent by the SearchResult.Id like so:
private void GetContent(SearchResult searchResult)
var content = _contentService.GetById(searchResult.Id);
// do stuff with content
Right now using ISearchResult we are not able to get content, as its Id property was changed to string in new version of Examine.
Do you know how can I achieve this in Umbraco 8?
The Id property still holds the numeric ID, but now as a string. So _contentService.GetById(int.Parse(searchResult.Id)) should do do the trick ;)
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted