c# - Image not updating in WPF view -
i have created 1 wpf application , created flipview control in while rendering have used following code
<controls:flipview x:name="flipviewcontrol" itemssource="{binding product.images}" selectedindex="0" selectionchanged="flipviewcontrol_selectionchanged"> <controls:flipview.itemtemplate> <datatemplate> <image source="{binding}" stretch="fill" /> </datatemplate> </controls:flipview.itemtemplate> </controls:flipview> the product.images observable collection of image uri's. when have changed product.images code behind view not updating.
private observablecollection<uri> images; public observablecollection<uri> images { { return images; } set { images = value; raisepropertychanged(); } } public void setimages(ienumerable<uri> images) { images.clear(); foreach (var image in images) { images.add(image); raisepropertychanged("product"); } } it still shows first image.what reason?
Comments
Post a Comment