Window.AllowsTransparency Property

Gets or sets the whether a window's client area supports transparency. This is a dependency property.

Namespace: System.Windows
Assembly: PresentationFramework (in presentationframework.dll)
XML Namespace:

public bool AllowsTransparency { get; set; }
/** @property */
public boolean get_AllowsTransparency ()

/** @property */
public void set_AllowsTransparency (boolean value)

public function get AllowsTransparency () : boolean

public function set AllowsTransparency (value : boolean)

<object AllowsTransparency="bool" .../>

Property Value

A Boolean object that specifies whether a window supports transparency.

Identifier field


Metadata properties set to true


Exception typeCondition


AllowsTransparency is changed after a window has been shown.


A window that has a WindowStyle value of anything other than None.

When the Background property of a window is set to a transparent color, using Transparent for example, the window remains opaque. This means that the desktop and any running applications "beneath" the window cannot be seen. To enable this type of transparency, AllowsTransparency must be set to true.

AllowsTransparency exists to facilitate the creation of non-rectangular windows, and, consequently, when AllowsTransparency is set to true, a window's WindowStyle property must be set to None.

For an example that demonstrates how to create a non-rectangular window using the AllowsTransparency property, see Non-Rectangular Windows Sample.

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0

Community Additions