How to open an XML file with the built-in XML editor in Eclipse

androideclipserss

I am learning how to make Android applications from HEAD FIRST ANDROID. In one chapter we are making an application which will show the NASA DAILY IMAGE on an Android phone. We are using RSS feeds in it. The book says:

Go to "http://www.nasa.gov/rss/image_of_the_day.rss".  
Save the page locally as .XML file.  
Open it with Eclipse. Then this file will be opened by Eclipse's built-in XML file editor, which looks something like this: 

xml editor image

But when the page is saved as .XML and it is opened with Eclipse, it looks like this:

Screenshot
(Click image to enlarge)

How do I open an .XML file in the required format as shown in the first image?

Best Answer

To open your XML file with Eclipse XML Editor :

  1. Start Eclipse
  2. Expand your project folder in Project Explorer window
  3. Copy/paste the XML file you have on your disk into your project folder within Eclipse.
  4. Then, in Eclipse, right-click the XML file
  5. Choose Open With --> XML Editor
Related Question