Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Starting PowerBI Exception Error

Feedback Type:
Frown (Error)

Error Message:
Resolution of the dependency failed, type = "Microsoft.PowerBI.Client.Windows.MainForm", name = "(none)".
Exception occurred while: Calling constructor Microsoft.PowerBI.Client.Windows.MainForm(Microsoft.Mashup.Client.UI.Shared.ILegacyUIHost uiHost, Microsoft.Mashup.DocumentServices.IExceptionHandler exceptionHandler, Microsoft.PowerBI.Client.Shared.IPowerBISettings powerBISettings, Microsoft.PowerBI.Client.Windows.IBrowserFactory browserFactory, Microsoft.PowerBI.Client.Windows.Services.IPowerBITelemetryService telemetryService, Microsoft.PowerBI.Client.Windows.Services.IPowerBIWindowServiceFactory windowServiceFactory, Microsoft.PowerBI.Client.Windows.Services.IUIBlockingService uiBlockingService, Microsoft.PowerBI.Client.Windows.Services.IEventAggregationService eventAggregationService).
Exception is: TypeInitializationException - The type initializer for 'Microsoft.PowerBI.Client.Windows.RibbonCommandSearcher' threw an exception.
-----------------------------------------------
At the time of the exception, the container was:

Resolving Microsoft.PowerBI.Client.Windows.MainForm,(none)
Calling constructor Microsoft.PowerBI.Client.Windows.MainForm(Microsoft.Mashup.Client.UI.Shared.ILegacyUIHost uiHost, Microsoft.Mashup.DocumentServices.IExceptionHandler exceptionHandler, Microsoft.PowerBI.Client.Shared.IPowerBISettings powerBISettings, Microsoft.PowerBI.Client.Windows.IBrowserFactory browserFactory, Microsoft.PowerBI.Client.Windows.Services.IPowerBITelemetryService telemetryService, Microsoft.PowerBI.Client.Windows.Services.IPowerBIWindowServiceFactory windowServiceFactory, Microsoft.PowerBI.Client.Windows.Services.IUIBlockingService uiBlockingService, Microsoft.PowerBI.Client.Windows.Services.IEventAggregationService eventAggregationService)


Stack Trace:
Microsoft.Practices.Unity.ResolutionFailedException
at Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, Object existing, String name, IEnumerable`1 resolverOverrides)
at Microsoft.Practices.Unity.UnityContainer.Resolve(Type t, String name, ResolverOverride[] resolverOverrides)
at Microsoft.Practices.Unity.UnityContainerExtensions.Resolve[T](IUnityContainer container, ResolverOverride[] overrides)
at Microsoft.Mashup.Host.Document.DependencyInjectionService.Resolve[T](String name)
at Microsoft.PowerBI.Client.Program.<>c__DisplayClass4_1.<Main>b__2()
at Microsoft.PowerBI.Client.Windows.IExceptionHandlerExtensions.<>c__DisplayClass3_0.<HandleExceptionsWithNestedTasks>b__0()
at Microsoft.Mashup.Host.Document.ExceptionHandlerExtensions.HandleExceptions(IExceptionHandler exceptionHandler, Action action)

Stack Trace Message:
Resolution of the dependency failed, type = "Microsoft.PowerBI.Client.Windows.MainForm", name = "(none)".
Exception occurred while: Calling constructor Microsoft.PowerBI.Client.Windows.MainForm(Microsoft.Mashup.Client.UI.Shared.ILegacyUIHost uiHost, Microsoft.Mashup.DocumentServices.IExceptionHandler exceptionHandler, Microsoft.PowerBI.Client.Shared.IPowerBISettings powerBISettings, Microsoft.PowerBI.Client.Windows.IBrowserFactory browserFactory, Microsoft.PowerBI.Client.Windows.Services.IPowerBITelemetryService telemetryService, Microsoft.PowerBI.Client.Windows.Services.IPowerBIWindowServiceFactory windowServiceFactory, Microsoft.PowerBI.Client.Windows.Services.IUIBlockingService uiBlockingService, Microsoft.PowerBI.Client.Windows.Services.IEventAggregationService eventAggregationService).
Exception is: TypeInitializationException - The type initializer for 'Microsoft.PowerBI.Client.Windows.RibbonCommandSearcher' threw an exception.
-----------------------------------------------
At the time of the exception, the container was:

Resolving Microsoft.PowerBI.Client.Windows.MainForm,(none)
Calling constructor Microsoft.PowerBI.Client.Windows.MainForm(Microsoft.Mashup.Client.UI.Shared.ILegacyUIHost uiHost, Microsoft.Mashup.DocumentServices.IExceptionHandler exceptionHandler, Microsoft.PowerBI.Client.Shared.IPowerBISettings powerBISettings, Microsoft.PowerBI.Client.Windows.IBrowserFactory browserFactory, Microsoft.PowerBI.Client.Windows.Services.IPowerBITelemetryService telemetryService, Microsoft.PowerBI.Client.Windows.Services.IPowerBIWindowServiceFactory windowServiceFactory, Microsoft.PowerBI.Client.Windows.Services.IUIBlockingService uiBlockingService, Microsoft.PowerBI.Client.Windows.Services.IEventAggregationService eventAggregationService)


Invocation Stack Trace:
at Microsoft.Mashup.Host.Document.ExceptionExtensions.GetCurrentInvocationStackTrace()
at Microsoft.Mashup.Client.UI.Shared.StackTraceInfo..ctor(String exceptionStackTrace, String invocationStackTrace, String exceptionMessage)
at Microsoft.PowerBI.Client.Windows.Telemetry.PowerBIUserFeedbackServices.GetStackTraceInfo(Exception e)
at Microsoft.PowerBI.Client.Windows.Telemetry.PowerBIUserFeedbackServices.ReportException(IWindowHandle activeWindow, IUIHost uiHost, FeedbackPackageInfo feedbackPackageInfo, Exception e, Boolean useGDICapture)
at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.<>c__DisplayClass14_0.<HandleException>b__0()
at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.PowerBI.Client.PowerBIUnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.Mashup.Host.Document.ExceptionHandlerExtensions.HandleExceptions(IExceptionHandler exceptionHandler, Action action)
at Microsoft.PowerBI.Client.Program.Main(String[] args)


PowerBINonFatalError:
{"AppName":"PBIDesktop","AppVersion":"2.103.661.0","ModuleName":"Microsoft.PowerBI.Client.Windows.dll","Component":"Microsoft.PowerBI.Client.Windows.RibbonCommandSearcher","Error":"System.TypeInitializationException","MethodDef":".ctor","ErrorOffset":"0"}

InnerException0.Stack Trace Message:
The type initializer for 'Microsoft.PowerBI.Client.Windows.RibbonCommandSearcher' threw an exception.

InnerException0.Stack Trace:
at Microsoft.PowerBI.Client.Windows.RibbonCommandSearcher..ctor(String indexFolderPath, IPowerBITelemetryService telemetryService)
at Microsoft.PowerBI.Client.Windows.RibbonSearchHostService..ctor(HostServiceDispatcher dispatcher, IPromiseStore promiseStore, IPowerBITelemetryService telemetryService, IApplicationConstants constants, String indexFolderName)
at Microsoft.PowerBI.Client.Windows.HtmlControls.ReportView.MinervaInterop.ReportViewInteropHost..ctor(Form form, IBrowserWrapper browserWrapper, IExplorationClientHost explorationClientHost, IReportManager reportManager, ISynchronizedModelOperationQueue synchronizedModelOperationQueue, IModelAuthoringRoutingService modelAuthoringRoutingService, ITelemetryContextProvider telemetryContextProvider, IPowerBITelemetryService telemetryService, ICloudConfigurationManager cloudManager, IUIBlockingService uiBlockingService, IWarningNotificationService warningService, IEventAggregationService eventAggregationService, IFeatureSwitchManager featureSwitchManager, IHostedScriptAsync hostedScript, IExploreClient exploreBackend, IPowerBIConstants powerBIConstants, IPowerBISettings powerBISettings, IPowerBIServiceClient powerBIServiceClient, IAuthenticationUIHandler authenticationUIHandler, IAuthenticationManager authenticationManager, IHttpService httpService, IUISettings uiSettings, IApplicationCommands applicationCommands, Func`1 isExplorationLoaded, IAccessibilityService accessibilityService, ILegacyUIHost uiHost, IExceptionHandler exceptionHandler, IPowerBIWindowService windowService, IExternalToolsManager externalToolsManager)
at Microsoft.PowerBI.Client.Windows.ReportViewClientHost..ctor(Form form, IBrowserWrapper browserWrapper, ILegacyUIHost uiHost, IExceptionHandler exceptionHandler, IPowerBIWindowService windowService, IEventAggregationService eventAggregationService, IQueryServicesProvider queryServicesProvider, IModelAuthoringRoutingService modelAuthoringRoutingService, IDesktopModelingHost modelingHost, ISynchronizedModelOperationQueue synchronizedModelOperationQueue, SynchronizationContext synchronizationContext, ITelemetryContextProvider telemetryContextProvider, IFeatureSwitchManager featureSwitchManager, IPowerBITelemetryService telemetryService, IReportManager reportManager, IExploreClient exploreClient, IPowerViewService powerViewService, IPowerBIConstants powerBIConstants, IPowerBISettings powerBISettings, ICloudConfigurationManager cloudManager, IUIBlockingService uiBlockingService, IWarningNotificationService warningService, IPowerBIServiceClient powerBIServiceClient, IAuthenticationUIHandler authenticationUIHandler, IAuthenticationManager authenticationManager, IHttpService httpService, IApplicationCommands applicationCommands, IUISettings uiSettings, IAccessibilityService accessibilityService, IExternalToolsManager externalToolsManager, IMinervaModalDialogManager minervaDialogManager, IWebView2VersionUtils webView2VersionUtils)
at Microsoft.PowerBI.Client.Windows.Views.ReportView..ctor(Form form, ICefBrowserHost host, ILegacyUIHost uiHost, IPowerBIWindowService windowService, IExceptionHandler exceptionHandler, IEventAggregationService eventAggregationService, IFeatureSwitchManager featureSwitchManager, IPowerBITelemetryService telemetryService, IApplicationCommands applicationCommands, IBrowserFactory browserFactory)
at Microsoft.PowerBI.Client.Windows.MainForm.CreateReportView()
at Microsoft.PowerBI.Client.Windows.MainForm..ctor(ILegacyUIHost uiHost, IExceptionHandler exceptionHandler, IPowerBISettings powerBISettings, IBrowserFactory browserFactory, IPowerBITelemetryService telemetryService, IPowerBIWindowServiceFactory windowServiceFactory, IUIBlockingService uiBlockingService, IEventAggregationService eventAggregationService)
at BuildUp_Microsoft.PowerBI.Client.Windows.MainForm(IBuilderContext )
at Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context)
at Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context)
at Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, Object existing, String name, IEnumerable`1 resolverOverrides)

InnerException0.Invocation Stack Trace:
at Microsoft.Mashup.Host.Document.ExceptionExtensions.GetCurrentInvocationStackTrace()
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo.GetFeedbackValuesFromException(Exception e, String prefix)
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo.GetFeedbackValuesFromInnerExceptions(Exception e, Int32 depth)
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo.CreateAdditionalErrorInfo(Exception e)
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo..ctor(String message, Exception exception, Nullable`1 stackTraceInfo, String messageDetail)
at Microsoft.PowerBI.Client.Windows.Telemetry.PowerBIUserFeedbackServices.ReportException(IWindowHandle activeWindow, IUIHost uiHost, FeedbackPackageInfo feedbackPackageInfo, Exception e, Boolean useGDICapture)
at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.<>c__DisplayClass14_0.<HandleException>b__0()
at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.PowerBI.Client.PowerBIUnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.Mashup.Host.Document.ExceptionHandlerExtensions.HandleExceptions(IExceptionHandler exceptionHandler, Action action)
at Microsoft.PowerBI.Client.Program.Main(String[] args)


InnerException1.Stack Trace Message:
Method not found: 'Lucene.Net.Documents.FieldType Lucene.Net.Documents.FieldType.Freeze()'.

InnerException1.Stack Trace:
at Microsoft.PowerBI.Client.Windows.RibbonCommandSearcher..cctor()

InnerException1.Invocation Stack Trace:
at Microsoft.Mashup.Host.Document.ExceptionExtensions.GetCurrentInvocationStackTrace()
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo.GetFeedbackValuesFromException(Exception e, String prefix)
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo.GetFeedbackValuesFromInnerExceptions(Exception e, Int32 depth)
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo.GetFeedbackValuesFromInnerExceptions(Exception e, Int32 depth)
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo.CreateAdditionalErrorInfo(Exception e)
at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo..ctor(String message, Exception exception, Nullable`1 stackTraceInfo, String messageDetail)
at Microsoft.PowerBI.Client.Windows.Telemetry.PowerBIUserFeedbackServices.ReportException(IWindowHandle activeWindow, IUIHost uiHost, FeedbackPackageInfo feedbackPackageInfo, Exception e, Boolean useGDICapture)
at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.<>c__DisplayClass14_0.<HandleException>b__0()
at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.PowerBI.Client.PowerBIUnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.Mashup.Host.Document.ExceptionHandlerExtensions.HandleExceptions(IExceptionHandler exceptionHandler, Action action)
at Microsoft.PowerBI.Client.Program.Main(String[] args)


PowerBIUserFeedbackServices_IsReported:
True

 

 

Status: Investigating
Comments
v-yetao1-msft
Community Support
manuphus
New Member

I have been getting the exact same error since updating to the latest version. Please keep us posted on the fix, as our development is blocked. The work arounds from other posts do not work.

GSS
Regular Visitor

I also have this same error.  Tried de-installing, removing all trace of Power BI Desktop, then re-installing.  Still fails to render a window.  The application is running, as seen on Task Manager, but is not visible.

fixmyissue
Regular Visitor

The only fix I could find was to install again, but this time not use the same default directory, instead install into a new directory of C:\Program Files\Microsoft Power BI Desktop, slightly change the name to say C:\Program Files\Microsoft Power BI Desktop v2 or something similar.

 

manuphus
New Member

I have a temporary work around, the pbix file open or the shortcut or the default open action of PowerBI still throws the error. But the second 'App' icon does load it ok.

 

manuphus_0-1649382583005.png

 

GSS
Regular Visitor

I worked around this by uninstalling, deleting all Power BI directories in AppData and Program Files, then installing the version from December 2021 (Version: 2.100.684.0 64-bit ), which fortunately a collegue still had.

Not ideal, but got me working again.  I think I'll wait for April's version before doing anything more.

Bryan080780
New Member

Thank you so much "fixmyissue" uninstalling powerbi and reinstalling to a new (non default directory) finally fixed our company's issue which started after a powerbi upgrade