Loading an image in SilverLight at run-time.
Drag an image control onto the design surface. Call it SampleImage.
if (Uri.IsWellFormedUriString(UrlTextBox.Text, UriKind.RelativeOrAbsolute))
{
BitmapImage bi = new BitmapImage();
bi.UriSource = new Uri(UrlTextBox.Text, UriKind.RelativeOrAbsolute);
SampleImage.Source = bi;
}
No comments:
Post a Comment
Remember, if you want me to respond to your comment, then you need to use a Google/OpenID account to leave the comment.