Windows Dev Center

The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

UIElement.BitmapEffect Property

Gets or sets a bitmap effect that applies directly to the rendered content for this element. This is a dependency property.

Namespace: System.Windows
Assembly: PresentationCore (in presentationcore.dll)
XML Namespace:

public BitmapEffect BitmapEffect { get; set; }
/** @property */
public BitmapEffect get_BitmapEffect ()

/** @property */
public void set_BitmapEffect (BitmapEffect value)

public function get BitmapEffect () : BitmapEffect

public function set BitmapEffect (value : BitmapEffect)

For XAML information, see the BitmapEffect type.

Property Value

The bitmap effect to apply.

Identifier field


Metadata properties set to true


BitmapEffect is an abstract type, therefore the XAML usage requires an implemented derived class of BitmapEffect, such as OuterGlowBitmapEffect. Note that one implemented derived class is a collection type that allows you to specify more than one sequential BitmapEffect, using a nested tag syntax.

No existing derived class of BitmapEffect supports a type converter, so the XAML syntax that you use for this property is generally property element syntax.

The following example sets a bitmap effect, using BlurBitmapEffect.

// Get a reference to the Button.
Button myButton = (Button)sender;

// Initialize a new BlurBitmapEffect that will be applied
// to the Button.
BlurBitmapEffect myBlurEffect = new BlurBitmapEffect();

// Set the Radius property of the blur. This determines how 
// blurry the effect will be. The larger the radius, the more
// blurring. 
myBlurEffect.Radius = 10;

// Set the KernelType property of the blur. A KernalType of "Box"
// creates less blur than the Gaussian kernal type.
myBlurEffect.KernelType = KernelType.Box;

// Apply the bitmap effect to the Button.
myButton.BitmapEffect = myBlurEffect;

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

© 2015 Microsoft