Vulnerability in EPiServer.Forms

Try our conversational search powered by Generative AI!

Projections not working?


I am trying to use projections to minimize the amount of data that are returned from the Find server but I got this error:

Error setting value to 'Category' on 'ProductPage'

I am using code that looks like this:

var searchQuery = _searchClient.Search(Language.Swedish)
                    .Filter(f => f.Cities.In(locations, true));
                    searchQuery.Select(s => new 
                        Title = s.Title,
                        LinkUrl = s.LinkUrl

var result = searchQuery.GetResult();

Anyone got a clue on how it could be like this?

May 11, 2015 15:31

Your example isn't cahined. Either you need to do:

searchQuery = searchQuery.Select(...)

or continue:



May 18, 2015 15:19

Thanks, I was blind......

of course it should be like that, thanks for seeing what I missed... ;-)

May 18, 2015 15:28
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.