ARTICLE

Image Control in Silverlight using VB.NET

Posted by Alok Pandey Articles | Silverlight using VB.NET September 13, 2011
In this article we will learn about Image Control and its main properties in Silverlight using VB.NET.
 
Reader Level:

Introduction: We use image control to show image in our application. It is essential control for displaying image in our application.

For example, We take a Silverlight application and then take one Image control. Then we go to Source property of Image and select a image for image control. Then, we go to Stretch property. This property defines how the image will be stretch. There are four values for this property.

  • None: If we set this value to Stretch property, then image will display in original size. But, only that part of image will be displayed which will be fit with image control size from top left of original image. The output will be as following image

    Image Control

  • Fill: If we set this value, the image control gets completely fills with the original image to which we  have added to image control by Source property. It generally fills the whole area of image control with source image. 

    Image Control

  • Uniform: It fills the source image into image control without disturbing its aspect ratio. It does't fills whole area of image control with image, but it looks for it's best appearance.

    Image Control


  • UniformToFill: It fills the image control with source image according to size of image control without disturbing aspect ratio of source image.

    Image Control


Login to add your contents and source code to this article
share this article :
post comment
 
Team Foundation Server Hosting
Become a Sponsor
PREMIUM SPONSORS
  • Get 2 Months Free of ASP.NET Hosting for Only $4.95/month! Receive FREE MS SQL and MySQL Databases Including ASP.NET 4/3.5, MVC 3.0, Silverlight 4, Windows 2008/IIS 7.0 Plus FREE IIS 7 Modules. Host UNLIMITED ASP.NET Web Sites - Click Here!
    Get 2 Months Free of ASP.NET Hosting for Only $4.95/month! Receive FREE MS SQL and MySQL Databases Including ASP.NET 4/3.5, MVC 3.0, Silverlight 4, Windows 2008/IIS 7.0 Plus FREE IIS 7 Modules. Host UNLIMITED ASP.NET Web Sites - Click Here!
Nevron Diagram
Become a Sponsor