Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

SilverLight 4: how to dynamically change the source of an Image?

Posted on 2010-08-16
2
731 Views
Last Modified: 2013-12-17
Hi Experts:

    I am making a SilverLight 4 program in which I want an image to be changed when user click a button.
    This is simple and straight forward if I am implementing desktop or ASP program: just build the bitmap with the new image URI  (hard-coded in the code) and assign the bitmap to Image.Source property.
    However, it seems non-trivial to me in SilverLight, because the application is hosted in the server but executed in the client. The client computer wouldn't have the path specified by the URI.
    Can you tell me how to make it work? If there is an example then it will be great.
    Thank you.
0
Comment
Question by:huangs3
2 Comments
 
LVL 18

Accepted Solution

by:
Anil Golamari earned 500 total points
ID: 33447306
http://www.xdevsoftware.com/blog/post/Dynamically-Loading-Images-in-SilverLight-10-using-C.aspx

http://forums.silverlight.net/forums/p/761/1511.aspx

Hope these provide you some information on dynamically loading images in silverlight.

Good Luck.
0
 

Author Comment

by:huangs3
ID: 33461158
Hi lucky85:

    Your links are relevant. Using the key "Dynamically-Loading-Image" I got an easy to follow link
http://blogs.silverlight.net/blogs/msnow/archive/2008/06/06/dynamically-loading-and-display-images-in-beta-2.aspx

0

Featured Post

Space-Age Communications Transitions to DevOps

ViaSat, a global provider of satellite and wireless communications, securely connects businesses, governments, and organizations to the Internet. Learn how ViaSat’s Network Solutions Engineer, drove the transition from a traditional network support to a DevOps-centric model.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
For most people, the WrapPanel seems like a magic when they switch from WinForms to WPF. Most of us will think that the code that is used to write a control like that would be difficult. However, most of the work is done by the WPF engine, and the W…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

790 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question