Gets or sets the ImageSource for the image.
Assembly: PresentationFramework (in PresentationFramework.dll)
XMLNS for XAML: http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation
The following example demonstrates how to use the property.
Image myImage3 = new Image(); BitmapImage bi3 = new BitmapImage(); bi3.BeginInit(); bi3.UriSource = new Uri("smiley_stackpanel.PNG", UriKind.Relative); bi3.EndInit(); myImage3.Stretch = Stretch.Fill; myImage3.Source = bi3;
|How to: Use the Image Element||This example shows how to include images in an application by using the Image element.|
|How to: Use a Drawing as an Image Source||This example shows how to use a Drawing as the for an Image control. To display a Drawing with an Image control, use a DrawingImage as the Image control's and set the DrawingImage object's DrawingImage.Drawing property to the drawing you want to display.|
|How to: Crop an Image||This example shows how to crop an image using CroppedBitmap.|
|How to: Rotate an Image||This example shows how to rotate an image 90 degrees by using a Rotation property of a BitmapImage.|
|How to: Convert an Image to Greyscale||This example shows how to convert an image to grayscale using FormatConvertedBitmap.|