I've tried [JsonIgnore] on the property and
SearchClient.Instance.Conventions.ForInstancesOf<PageDataBase>().ExcludeField(x => x.Ikon);
in Global.asax.cs, but reindexing and rebuilding still hits the pages with a string matching Ikon (string, css class icon)
When I inspect the index I find:
Why isn't Ikons value excluded from searchText, just from the document?
How can I solve this? Override searchText (!?)
Thanks in advance!
In admin mode you need to "unclick" that the property is searchable. Admin -> Page Types -> Select Page Type -> CLick property-> "unclick"
Is there a way to do this by code in EPiServer 7 CMS MVC?
Adding [Searchable(false)] worked nicely, thanks for pointing me in the right direction :)
Your welcome. For others reading this post with the same concerns. Remember that you have to reindex after changing this for the changes to be propagted to the index.