I have a fresh windows installation, where i just installed office 2016. When i try to open, or create a new connection to our database i get this error:
Error Message:
Unable to cast object of type 'System.__ComObject' to type 'Microsoft.Mashup.Client.Excel.TaskPaneControl'.
Stack Trace:
System.InvalidCastException: Unable to cast object of type 'System.__ComObject' to type 'Microsoft.Mashup.Client.Excel.TaskPaneControl'.
at System.Runtime.InteropServices.Marshal.GetTypedObjectForIUnknown(IntPtr pUnk, Type t)
at Microsoft.Mashup.Client.Excel.NativeExcelFunctions.Microsoft.Mashup.Client.Excel.INativeExcelFunctions.TryGetTaskPaneControl(NativeTaskPaneType type, IntPtr uiFrame, TaskPaneControl& taskPaneControl)
at Microsoft.Mashup.Client.Excel.Shim.NativeTaskPaneServices.NativeTaskPane.get_ContentControl()
at Microsoft.Mashup.Client.Excel.Shim.NativeTaskPaneServices.TryGetCustomTaskPane(TaskPaneType taskPaneType, ExcelWindowId excelWindowId, ITaskPane& taskPane)
at Microsoft.Mashup.Client.Excel.CustomTaskPaneManager.TryGetCustomTaskPane(ExcelWindowId windowId, ITaskPane& taskPane)
at Microsoft.Mashup.Client.Excel.CustomTaskPaneManager.TryGetTaskPaneControl[T](ExcelWindowId windowId, T& taskPaneControl)
at Microsoft.Mashup.Client.Excel.CustomTaskPaneManager.OnWindowDeactivate(IWindowContext windowContext)
at Microsoft.Mashup.Client.Excel.CustomTaskPaneManagers.OnWindowDeactivate(IWindowContext windowContext)
at Microsoft.Mashup.Client.Excel.NativeEventHandler.<>c__DisplayClass1d.<OnWindowDeactivate>b__1c()
at Microsoft.Mashup.Host.Document.ExceptionHandlerExtensions.HandleExceptions(IExceptionHandler exceptionHandler, Action action)
Invocation Stack Trace:
at Microsoft.Mashup.Host.Document.ExceptionExtensions.GetCurrentInvocationStackTrace()
at Microsoft.Mashup.Client.ClientShared.UnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.Mashup.Host.Document.ExceptionHandlerExtensions.HandleExceptions(IExceptionHandler exceptionHandler, Action action)
at Microsoft.Mashup.Client.Excel.NativeEventHandler.OnWindowDeactivate(IntPtr uiFrame)
at Microsoft.Mashup.Client.Excel.NativeExcelConnector.<>c__DisplayClass5d.<OnWindowDeactivateCallback>b__5c()
at Microsoft.Mashup.Client.Excel.NativeExcelConnector.InvokeAndReturnHResult(Action action)
at Microsoft.Mashup.Client.Excel.NativeExcelConnector.OnWindowDeactivateCallback(IntPtr uiFrame)
at System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.OnComponentEnterState(Int32 dwComponentID, Int32 uStateID, Int32 uContext, Int32 cpicmExclude, Int32 rgpicmExclude, Int32 dwReserved)
at System.Windows.Forms.ComponentManagerProxy.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.OnComponentEnterState(Int32 dwComponentID, Int32 uStateID, Int32 uContext, Int32 cpicmExclude, Int32 rgpicmExclude, Int32 dwReserved)
at System.Windows.Forms.Application.ThreadContext.BeginModalMessageLoop(ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.RunDialog(Form form)
at System.Windows.Forms.Form.ShowDialog(IWin32Window owner)
at Microsoft.Mashup.Client.ClientShared.WindowManager.ShowDialog[T](T form, IWin32Window owner)
at Microsoft.Mashup.Client.ClientShared.Ux.FloatingDialog.SimpleDialog.UnexpectedErrorDialog.Show(IWin32Window owner, WindowsHost windowsHost, String message, Nullable`1 errorCode, String requestId, String exceptionStackTrace, String invocationStackTrace, PackageReference
sourcePackageReference, Boolean displayOnTop)
at Microsoft.Mashup.Client.ClientShared.UnexpectedExceptionHandler.<>c__DisplayClass1.<HandleException>b__0()
at Microsoft.Mashup.Host.Document.SynchronizationContextExtensions.Send(SynchronizationContext context, IExceptionHandler exceptionHandler, Action callback)
at Microsoft.Mashup.Client.ClientShared.UnexpectedExceptionHandler.HandleException(Exception e)
at Microsoft.Mashup.Host.Document.ExceptionHandlerExtensions.HandleExceptions(IExceptionHandler exceptionHandler, Action action)
at Microsoft.Mashup.Client.Excel.NativeEventHandler.OnIdle()
at Microsoft.Mashup.Client.Excel.NativeExcelConnector.<OnIdleCallback>b__3c()
at Microsoft.Mashup.Client.Excel.NativeExcelConnector.InvokeAndReturnHResult(Action action)
at Microsoft.Mashup.Client.Excel.NativeExcelConnector.OnIdleCallback()