web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Pages / Error when making a se...
Power Pages
Answered

Error when making a search on Power Pages - YSOD

(0) ShareShare
ReportReport
Posted on by 105

Could someone please help me understand this error:

[NullReferenceException: Object reference not set to an instance of an object.]
 Adxstudio.Xrm.Search.DataverseSearch.Providers.Filters.KnowledgeArticleFilterConfigProvider.TryGetLanguageCode(String& languageID) in C:\__w\1\s\Framework\Adxstudio.Xrm\Search\DataverseSearch\Providers\Filters\KnowledgeArticleFilterConfigProvider.cs:78
 Adxstudio.Xrm.Search.DataverseSearch.Providers.Filters.KnowledgeArticleFilterConfigProvider.GetFilters(IEnumerable`1 facetConstraints) in C:\__w\1\s\Framework\Adxstudio.Xrm\Search\DataverseSearch\Providers\Filters\KnowledgeArticleFilterConfigProvider.cs:37
 Adxstudio.Xrm.Search.DataverseSearch.Providers.DataverseSearchFilterProvider.GetFilters(String entityName, IEnumerable`1 facetConstraints) in C:\__w\1\s\Framework\Adxstudio.Xrm\Search\DataverseSearch\Providers\DataverseSearchFilterProvider.cs:54
 Adxstudio.Xrm.Search.DataverseSearch.Providers.SearchEntityProvider.GetEntity(String entityName, IEnumerable`1 facetConstraints) in C:\__w\1\s\Framework\Adxstudio.Xrm\Search\DataverseSearch\Providers\SearchEntityProvider.cs:55
 Adxstudio.Xrm.Search.DataverseSearch.Providers.SearchEntityCollectionProvider.GetEntitiesList(List`1 logicalNames, IEnumerable`1 facetConstraints) in C:\__w\1\s\Framework\Adxstudio.Xrm\Search\DataverseSearch\Providers\SearchEntityCollectionProvider.cs:61
 Adxstudio.Xrm.Search.DataverseSearch.DataverseSearchQuery..ctor(String queryText, Int32 pageNumber, Int32 pageSize, String filter, List`1 logicalNames, IWebsiteLanguage language, Boolean multiLanguageEnabled, Int32 postProcessingLimit, IEnumerable`1 facetConstraints, Boolean isFacetedSearch, Boolean isGlobalSearch, String sortingOption, Int32 top, Int32 skip) in C:\__w\1\s\Framework\Adxstudio.Xrm\Search\DataverseSearch\DataverseSearchQuery.cs:84
 Adxstudio.Xrm.Web.UI.WebControls.SearchDataSourceView.ExecuteSelect(DataSourceSelectArguments args) in C:\__w\1\s\Framework\Adxstudio.Xrm\Web\UI\WebControls\SearchDataSourceView.cs:69
 Adxstudio.Xrm.Web.UI.WebControls.SearchDataSourceInfoView.ExecuteSelect(DataSourceSelectArguments args) in C:\__w\1\s\Framework\Adxstudio.Xrm\Web\UI\WebControls\SearchDataSourceInfoView.cs:17
 System.Web.UI.WebControls.Repeater.GetData() +335
 System.Web.UI.WebControls.Repeater.CreateControlHierarchy(Boolean useDataSource) +286
 System.Web.UI.WebControls.Repeater.OnDataBinding(EventArgs e) +79
 System.Web.UI.WebControls.Repeater.EnsureDataBound() +142
 System.Web.UI.WebControls.Repeater.OnPreRender(EventArgs e) +19
 System.Web.UI.Control.PreRenderRecursiveInternal() +199
 System.Web.UI.Control.PreRenderRecursiveInternal() +296
 System.Web.UI.Control.PreRenderRecursiveInternal() +296
 System.Web.UI.Control.PreRenderRecursiveInternal() +296
 System.Web.UI.Control.PreRenderRecursiveInternal() +296
 System.Web.UI.Control.PreRenderRecursiveInternal() +296
 System.Web.UI.Control.PreRenderRecursiveInternal() +296
 System.Web.UI.Control.PreRenderRecursiveInternal() +296
 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +7478

 

I setup the global search/dataverse search for my portal (a blank template) and after successfully making queries from some custom tables, I decided to query the Knowledge Article table which I added to my solution. Since then, I have been receiving this error. I removed the KA from my solution and renamed the search view, so it does not get indexed. I have been stuck on this for the past 5 days.

Categories:
I have the same question (0)
  • Verified answer
    aofosu Profile Picture
    105 on at

    I was able to resolve this issue by doing the following steps:

    1. Removing the Knowledge Article table from the Dataverse Search Index (because I am using the Blank Template this feature is not searchable as the Content Access Level feature is not present)
    2. Setting this site settings "KnowledgeManagement/ContentAccessLevel/Enabled" to false
    3. Adding a MIME type "text/html" to the web template that renders the search results (this is because I have the "HTTP/X-Content-Type-Options" header set to "nosniff")

    I hope this helps if you do encounter this same error if you are not using any of the recommended Dynamics 365 templates that support the knowledge articles. 

    Workaround:
    Based on the client's requirements we decided to create custom tables to separate KA for anonymous and authenticated users. Then using the liquid searchindex we assign different logical names depending on the user type. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Pages

#1
Fubar Profile Picture

Fubar 26 Super User 2026 Season 1

#2
Lucas001 Profile Picture

Lucas001 19 Super User 2026 Season 1

#3
CN-06091549-0 Profile Picture

CN-06091549-0 18

Last 30 days Overall leaderboard