title: read xml and assign attributes to variables in vb.net
body: <p>I have a xml file</p>
  
  <pre><code>&lt;config&gt;
     &lt;email Host="201.175.0.0" From="address@gmail.com" Pass="xxx" Name="NameT"/&gt;
     &lt;combo/&gt;
     &lt;list sex="female"/&gt;
  &lt;/config&gt;
  </code></pre>
  
  <p>How can I assign the value of the attributes to variables in vb.net?</p>
  
  <p>I was doing </p>
  
  <pre><code>Dim doc As XmlDocument = New XmlDocument()
  doc.Load("Test.xml")
  Dim Host = doc.DocumentElement.Attributes.ItemOf("Host").InnerText
  Dim From = doc.DocumentElement.Attributes.ItemOf("From").InnerText
  Dim Pass = doc.DocumentElement.Attributes.ItemOf("Pass").InnerText
  Dim Name = doc.DocumentElement.Attributes.ItemOf("Name").InnerText
  </code></pre>
  
  <p>Is this correct, what would be a better approach? </p>