LEADTOOLS WPF and Silverlight (Leadtools.Windows.Controls assembly) Send comments on this topic. | Back to Introduction - All Topics | Help Version 17.0.3.30
Source Property
See Also 
Leadtools.Windows.Controls Namespace > ImageListItem Class : Source Property



Gets or sets the image associated with this ImageListItem object. This is a dependency property. Supported in Silverlight, Windows Phone 7

Syntax

Visual Basic (Declaration) 
<CategoryAttribute("Appearance")>
<DescriptionAttribute("Gets or sets the ImageSource for the ImageListItem).")>
Public Property Source As ImageSource
Visual Basic (Usage)Copy Code
Dim instance As ImageListItem
Dim value As ImageSource
 
instance.Source = value
 
value = instance.Source
C# 
[CategoryAttribute("Appearance")]
[DescriptionAttribute("Gets or sets the ImageSource for the ImageListItem).")]
public ImageSource Source {get; set;}
C++/CLI 
[CategoryAttribute("Appearance")]
[DescriptionAttribute("Gets or sets the ImageSource for the ImageListItem).")]
public:
property ImageSource^ Source {
   ImageSource^ get();
   void set (    ImageSource^ value);
}

Property Value

An System.Windows.Media.ImageSource object associated with this ImageListItem object. Default value is null (Nothing in Visual Basic).

Example

For XAML example, refer to ImageList.

For C#/VB examples, refer to ImageList.

Remarks

The ImageList control will draw this image onto the item surface. If the item does not have an image, the value of this property is null (Nothing in Visual Basic) and, nothing is drawn.

You can set the Source property directly with the item image or you can set the Uri property with the path to the image and let the control load the image.

Requirements

Target Platforms: Windows 2000, Windows XP, Windows Server 2003 family, Windows Server 2008 family

See Also