ToolWindow Activate method differences

Docking/MDI for Windows Forms Forum

Posted 8 years ago by Tom Johnson
Version: 16.1.0330

I have two floating tool windows.   Let's call them A and B.   B is covering up A.   A wants to display a message in its control and bought to the user's attention.  If I call, Activate(false) on A, nothing really seems to happen.   If I just call Activate(), A is moved to the top and gets focus.   I would like to move A above B and keep focus on whatever control in the rest of the app had focus.   Any suggestions?

Comments (1)

Posted 8 years ago by Actipro Software Support - Cleveland, OH, USA

Hi Tom,

I wonder if you could do ToolWindow.FindForm() to get the Form that is hosting the floating tool window.  You can't really call Activate() on that since I believe that will focus the Form's content too.  But you might be able to use the Windows API's SetWindowPos with SWP_NOACTIVATE as described in this thread:

That would likely let you bring the Form to the top without activating it.

Actipro Software Support

The latest build of this product (v24.1.0) was released 4 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.