Read XML file with attributes and write in excel sheet

I am trying to read a XML file with attributes and write in a excel sheet. I tried creating dataset using the readxml, it works for the xml file without attributes.Can anyone help me ? .
<---------This works---->


Gambardella, Matthew
XML Developer’s Guide


Ralls, Kim
Midnight Rain

<---------Not works—>