Select the search type
  • Site
  • Web
Search
You are here:  Support/Forums
Support

Bring2mind Forums

Custom attributed populated via search?
Last Post 06/03/2013 11:55 AM by Peter Donker. 1 Replies.
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
Darren Grayson
New Member
New Member
Posts:5


--
05/28/2013 3:26 PM
Hi Peter,

Can you tell me if the custom attributes collection is populated by the Search/GetSearchResults methods? It appears not to be in my case. If not, is there a way of getting it populated after calling GetSearchResults?

Below is the output from the VS2012 immediate window. "Entry" is an object of type SearchResultEntryInfo. Note finding the entry through EntriesController works as expected.

?Entry.EntryId
101
?Entry.EntryType
"File.Adobe.Acrobat"
?Entry.Deleted
false
?Entry.CustomAttributes.Count
0

?DMX.Entities.Entries.EntriesController.GetEntry(0,101).CustomAttributes.Count
4

I noticed there is a GetProperty method on the SearchResultEntryInfo object. However this only seems to return an empty string too.

DMX version 6.01.05 on DNN 7.0.3.

Regards,

Darren
Peter Donker
Veteran Member
Veteran Member
Posts:4536


--
06/03/2013 11:55 AM
Hi Darren,

It *should* return the attributes. Why don't you try the following: use SQL profiler to just double check what is happening at the DB level. The SQL to get the search results is dynamic and cached. It is dynamic for the reason that it needs to load in those attributes and craft the SQL to retrieve those results.

Peter
You are not authorized to post a reply.