Failed to create DAX script in SSMS v18.5.1 - Object reference not set to an instance of an object

442 views Asked by At

I am not able to open new "Analysis Services DAX Query" in SQL Server Management Studio (SSMS) v18.5.1. SSMS DAX Error print screen

Error details:

Failed to create new DAX script.

------------------------------
ADDITIONAL INFORMATION:

Object reference not set to an instance of an object. (   at Microsoft.VisualStudio.Text.Editor.Implementation.WpfTextView.UnsubscribeFromEvents()
   at Microsoft.VisualStudio.Text.Editor.Implementation.WpfTextView.Close()
   at Microsoft.VisualStudio.Text.Editor.Implementation.WpfTextViewHost.Close()
   at Microsoft.VisualStudio.Editor.Implementation.SimpleTextViewWindow.CloseExistingWpfTextView()
   at Microsoft.VisualStudio.Editor.Implementation.SimpleTextViewWindow.CloseBufferRelatedResources()
   at Microsoft.VisualStudio.Editor.Implementation.SimpleTextViewWindow.CloseView()
   at Microsoft.VisualStudio.Editor.Implementation.CompoundTextViewWindow.Close()
   at Microsoft.SqlServer.Management.UI.VSIntegration.ShellCodeWindowControl.UnsinkEventsAndFreeInterfaces()
   at Microsoft.SqlServer.Management.UI.VSIntegration.ShellTextEditorControl.Dispose(Boolean disposing)
   at System.ComponentModel.Component.Dispose()
   at Microsoft.SqlServer.Management.UI.VSIntegration.Editors.ScriptEditorControl.Dispose(Boolean bDisposing)
   at Microsoft.SqlServer.Management.UI.VSIntegration.Editors.ScriptAndResultsEditorControl.Dispose(Boolean bDisposing)
   at Microsoft.SqlServer.Management.UI.VSIntegration.Editors.MdxScriptEditorControl.Dispose(Boolean bDisposing)
   at Microsoft.SqlServer.Management.UI.VSIntegration.ShellWindowPaneUserControl.OnWindowPaneClose()
   at Microsoft.SqlServer.Management.UI.VSIntegration.ShellWindowPaneUserControl.ClosePane()
   at Microsoft.VisualStudio.Platform.WindowManagement.WindowPaneDocumentObject.<>c__DisplayClass19_0.<DisposeManagedResources>b__0()
   at Microsoft.VisualStudio.ErrorHandler.CallWithCOMConvention(Action method, Boolean reportError))

All other queries (MDX, DMX, XMLA) works fine, but DAX does not.

I have tried following to fix the issue:

Firstly I had tried re-install just SSMS.

When it did not work I have tried following steps still without success:

  1. uninstall Visual Studio 2019 with SQL Server Data Tools (SSDT)
  2. uninstall SSMS
  3. install VS 2019 with SSDT
  4. install SSMS

I tried to search for help on this issue, but I have not found any relevant information.

Thank you in advance for any suggestions.

My SSMS setup:

SQL Server Management Studio: 15.0.18333.0
SQL Server Management Objects (SMO): 16.100.37971.0
Microsoft Analysis Services Client Tools: 15.0.19153.0
Microsoft Data Access Components (MDAC): 10.0.18362.1
Microsoft MSXML: 3.0 6.0 
Microsoft .NET Framework: 4.0.30319.42000
Operating System: 10.0.18363

Part of my VS 19 setup:

Microsoft Visual Studio Professional 2019
Version 16.6.5
VisualStudio.16.Release/16.6.5+30320.27
Microsoft .NET Framework
Version 4.8.03752
Installed Version: Professional

Microsoft Visual Studio Tools for Applications 2019
Microsoft Visual Studio Tools for Applications 2019

SQL Server Analysis Services   15.0.19126.0
Microsoft SQL Server Analysis Services Designer 
Version 15.0.19126.0

SQL Server Data Tools   16.0.62006.03190
Microsoft SQL Server Data Tools

SsmsVsIntegration   1.0
0

There are 0 answers