ActiveDocument

Docking/MDI for WPF Forum

Posted 16 years ago by Iosu Buenetxea
Avatar
Hello!!

I have a dockSite with a TabbedMdiHost and a TabbedMdiContainer. At runtime, people can make new TabbedMdihost (and spliters come too). The thing I need is to know the ActiveDocument at any time. I could know the dockSite.ActiveWindow but the ToolWindows are windows too. I see also there is the dockSite.LastActiveDocument...but I can't find something as dockSite.ActiveDocument.
What's the best approach to do it?
Thanks in advance,
Iosu

Comments (1)

Posted 16 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
I believe LastActiveDocument will contain the currently focused document if you are in one. The logic we typically use to get the primary document is:
DockingWindow window = this.LastActiveDocument;
if (window == null)
    window = this.FindFirstDocument();


Actipro Software Support

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

Add Comment

Please log in to a validated account to post comments.