I need to convert System.Collections.Generic.IENumerable to System.Windows.Media.Imaging.BitmapImage
I select BitmapImage in LINQ syntax
var localStore = from n in ((App)Application.Current).global_local_store//this Local_ImagesStore
where n.url == url
select n.bitmp;//BitmapImage
public struct Local_ImagesStore
{
public string url;
public BitmapImage bitmp;
}
How do I convert this?
I can’t do this:
var result = new BitmapImage();
result=local_store;
return result;
You receive BitmapImage collection.
should work.
Check: http://msdn.microsoft.com/en-us/library/bb340482.aspx
Disclaimer: i never wrote silverlight for wp7.