XML : Unreadable XML File to Readable C#

So I have an XML file which gets information from imdb like that

  <?xml version="1.0" encoding="UTF-8"?><root response="True"><movie title="Game of Thrones" year="2011–" rated="TV-MA" released="17 Apr 2011" runtime="56 min" genre="Adventure, Drama, Fantasy" director="N/A" writer="David Benioff, D.B. Weiss" actors="Peter Dinklage, Lena Headey, Emilia Clarke, Kit Harington" plot="Several noble families fight for control of the mythical land of Westeros." language="English" country="USA" awards="Won 1 Golden Globe. Another 133 wins &amp; 248 nominations." poster="http://ia.media-imdb.com/images/M/MV5BNTgxOTI4NzY2M15BMl5BanBnXkFtZTgwMjY3MTM2NDE@._V1_SX300.jpg" metascore="N/A" imdbRating="9.5" imdbVotes="868,876" imdbID="tt0944947" type="series"/></root>    

But as you can see it doesn't use our rules so I cant get specific node info like imdbRating or poster

Basically what I want from this file I wanna get IMDB Rating info and write it to my label or textbox etc. I tried lots of other xml parse subjects from this site and I tried to edit them but none of them worked so far.

And that's the last thing what I want for my program so hopefully someone helps me :(

By the way I can't change the file format unfortunatelly site api doesnt allow me to do it.

Note: I can also print the file as txt or other forms it does always contains the same text like above

No comments:

Post a Comment