Don't miss out Virtual Happy Hour this Friday (April 26).

Try our conversational search powered by Generative AI!

Indexed custom object lacks content type name

Vote:
 

Hi,

I've inserted a custom object manually into the index, like this: SearchClient.Instance.Index(customObject). It's a simple class with string properties which should be no problem to serialize. It can be browsed in the Find index using Explore.

However, compared to the CMS pagedata objects automatically inserted by the indexing module it lacks "Content type name", "Content name" and other properties. The only set properties are "Index ID", "Index Type" and "Document source". When I try to fetch it using GetResult() I get the exception "Value cannot be null. Parameter name: contentType", which would relate to the missing properties.

How can I add these missing properties to the index? Is there a better way of inserting the object?

I'm using the latest version of the EPiServer Find binaries (7.0.586.16).

 

#73714
Aug 06, 2013 17:08
Vote:
 

Found the answer. The custom object must inherit from ISearchContent in order for UnifiedSearch to work.

#73765
Aug 08, 2013 13:30
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.