Julius
Julius

Reputation: 745

How do I prevent my Popup being covered by a new child window?

A popup, defined by my parent Window, is being covered by a child Window. I would like the popup to be displayed on top of all application windows.

My parent Window has Topmost="True" and contains the popup (with Placement="AbsolutePoint"), as well as an interaction request to launch the child Window. In the interaction request this occurs:

  1. Child Window is created with Topmost="True" and Owner=parentWindow
  2. Topmost is set to false on the parent window
  3. ShowDialog is called for the child Window

The popup is displayed on top of the parent Window, but below the child Window. I have tried turning ChildWindow.Topmost to "False", but this does not help.

Upvotes: 1

Views: 584

Answers (1)

Julius
Julius

Reputation: 745

Slightly unsatisfactory, but I'm going to redesign my approach so that I am using 2 popups, rather than 1 popup and 1 child window, which should have a z-order related to the order in which they are opened. This prevents another window showing on the taskbar also.

I believe the problem is stemming from the fact that popups are really just windows, and it is difficult to make 3 windows play nicely together. I have not found out which property/properties are responsible, but it will be some combination of Topmost, Owner and which window is currently Activated tripping me up.

Upvotes: 0

Related Questions