WindowHelperService.TrySetWindowOwner(DependencyObject, Window) Method

Definition

Assigns the window to be the owner of the specified window.

public bool TrySetWindowOwner (System.Windows.DependencyObject source, System.Windows.Window target);

Parameters

source
DependencyObject

The owner of target.

target
Window

The window that is to be owned by source.

Returns

true if the operation is successful; otherwise, false.

Applies to

产品 版本
.NET Framework 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1