2009.2.0515 - NullReferenceException

Docking/MDI for WPF Forum

Posted 10 years ago by Robert A. McCarter
Version: 9.2.0515
Platform: .NET 3.5
Environment: Windows Vista (64-bit)
Avatar
With version 9.1.507 my application worked fine; unfortunately, when I migrated to 9.2.515 my application started crashing.

My application has two types of documents: client documents and report documents.

My code is calling the following to ensure a toolbox window is expanded and docked for a report documents:
var toolboxWindow = MainWindow.Instance.ImportantToolWindow;
toolboxWindow.Dock();

and when a client document tab is active I automatically hide the tool window by calling toolboxWindow.AutoHide() (because it's not needed for client documents).

However, with version 9.2.515 when I try and open a new report document and show/pin the tool window then I get the following exception:

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object.
at ActiproSoftware.Windows.Controls.Docking.DockSite.a(DependencyObject A_0, DependencyObject A_1, Boolean A_2)
at ActiproSoftware.Windows.Controls.Docking.DockSite.a(DependencyObject A_0, DependencyObject A_1)
at ActiproSoftware.Windows.Controls.Docking.DockSite.a(DependencyObject A_0, EventNotifier A_1, Direction A_2, IList`1 A_3)
at ActiproSoftware.Windows.Controls.Docking.DockSite.a(DependencyObject A_0, EventNotifier A_1, Direction A_2)
at ActiproSoftware.Windows.Controls.Docking.DockSite.a(DependencyObject A_0, Direction A_1, Nullable`1 A_2)
at ActiproSoftware.Windows.Controls.Docking.DockSite.a(DependencyObject A_0, Nullable`1 A_1)
at ActiproSoftware.Windows.Controls.Docking.ToolWindow.Dock()

I migrated back to 9.1.507 and without changing a line of my own code the application works fine again, so that when I open a new tabbed report window and call the above code to ensure the toolbox is docked and visible everything works fine again.

Nothing in the release history suggets that this should be a problem...

I could really use a hand with this.

Thank you very much,

Robert A. McCarter

Comments (1)

Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Robert,

We're not aware of any issues, so we'd need to be able to repro this to help you. If you can repro it in our main demo with a couple lines of code to change then tell us how. Otherwise, please make as simple of a sample project that you can that repros it and email that over. Thanks!


Actipro Software Support

The latest build of this product (v2019.1 build 0683) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.