Click here to Skip to main content
15,894,241 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Hi,
I have an XML file. in that i have image tag.
as i am new to mvvm and linq to XML.

i am not able to read image tag with image. and want to display in image box using xaml and mvvm.

Please help me.
Posted
Updated 7-Dec-13 12:19pm
v2
Comments
Sergey Alexandrovich Kryukov 6-Dec-13 14:41pm    
What kind of image? It would be quite unusual if an image is encoded in XML, unless this is vector graphics. Anyway, the post is so non-informative that we have nothing to discuss it. Use "Improve question" if you can...
—SA
bunty swapnil 7-Dec-13 3:29am    
i have passed the image path in xml
<image href ="Pathoffile"/>

each root node have this tag.

i want to read all image and display using wpf
Sergey Alexandrovich Kryukov 7-Dec-13 18:15pm    
And what's the problem then? What, you don't know how to read image from file?
—SA

1 solution

You can use the class System.Windows.Media.Imaging.BitmapImage, see the MSDN article on it with code samples:
http://msdn.microsoft.com/en-us/library/system.windows.media.imaging.bitmapimage%28v=vs.110%29.aspx[^].

—SA
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900