난 처음에 Image를 넣어야 하는줄 알았더니 BitMapImage를 넣어야 하는것이였다.
사용하는 부분은 이렇게 이고
ItemImageSource = new BitmapImage(new Uri("/HugeFlow.FortuneCoins;component/Images/item/Coins_9.png", UriKind.RelativeOrAbsolute));
private BitmapImage _ItemImageSource;
/// <summary>
/// TODO:아이템 이미지 변경
/// </summary>
public BitmapImage ItemImageSource
{
get
{
return _ItemImageSource;
}
set
{
_ItemImageSource = value;
OnPropertyChanged("ItemImageSource");
}
}
xaml코드에는<Image Source="{Binding ItemImageSource}" Stretch="Fill"/>
바인딩해서 사용하였다.
'Windows Phone 7' 카테고리의 다른 글
[wp7] 효율적인 isolatedStorageSetting 사용법 (0) | 2011.01.07 |
---|---|
[wp7] Observable Collection을 이용한 바인딩 (0) | 2011.01.06 |
[wp7] 분리된 어셈블리에 대해서 다국어 리소스지원 (1) | 2010.10.20 |
[wp7] Localization Resource 국제화 하는법 (0) | 2010.10.19 |
[wp7] 람다식을 잘쓰자. (0) | 2010.10.18 |