WindowsOpening and WindowsOpened events on DockSite do not take effect.

Docking/MDI for WPF Forum

Posted 1 year ago by Sunshine - Appeon
Version: 22.1.1

I subscribe to the event on DockSite directly by the following code.

this.Content.dockSite.WindowsOpening += this.DockSite_WindowsOpening;
this.Content.dockSite.WindowsOpened += this.DockSite_WindowsOpened;
this.Content.dockSite.WindowsClosed += this.DockSite_WindowsClosed;
this.Content.dockSite.WindowsClosing += this.DockSite_WindowsClosing;

Then I create a ToolWindow and call the Open method to open it:

var window = new ToolWindow(this.Content.dockSite);

At this time, the Open-related events are not triggered, but the Close-related events are triggered when the ToolWindow is closed.

What could be the reason for this please? Our scene is not using MVVM way.

Comments (1)

Posted 1 year ago by Actipro Software Support - Cleveland, OH, USA


I opened our main demo and added the lines where you create and open the ToolWindow to a menu item event handler.  When I execute those, I see the WindowsOpening and WindowsOpened events firing in the Output tool window. 

It seems to be working fine here and nothing has changed in this area in a long time.  If you still think there is a problem, please reproduce it in a new simple sample project and send that to our support address so that we can debug the scenario.  Be sure to exclude the bin/obj folders from the .zip you send so it doesn't get spam blocked.  Thanks!

Actipro Software Support

The latest build of this product (v23.1.3) was released 17 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.