c# - local bitmapimage(windows phone) -


i trying convey path <image x:name="flagimage" stretch="none" />, when run application image not displayed.

flagimage.source = new bitmapimage(new uri("/images/sky.jpg")); 

if change path url image displayed

flagimage.source = new bitmapimage(new uri("http://www.charlespetzold.com/media/hellowp7.jpg")); 

this code work too:

<image source="/images/sky.jpg"/> 

you have initialize bitmapimage urisource setting path relative..like this

  flagimage.source = new bitmapimage(new uri("/images/sky.jpg", urikind.relative)); 

hope helps you..


Comments

Popular posts from this blog

Unable to remove the www from url on https using .htaccess -