title: How can I read data from this XML in c#?
body: <pre><code>    &lt;?xml version="1.0"?&gt;
  &lt;!--
  ** DO NOT EDIT THIS FILE.
  ** If you make changes to this file while any VirtualBox related application
  ** is running, your changes will be overwritten later, without taking effect.
  ** Use VBoxManage or the VirtualBox Manager GUI to make changes.
  --&gt;
  &lt;VirtualBox xmlns="http://www.virtualbox.org/" version="1.12-windows"&gt;
    &lt;Global&gt;
      &lt;ExtraData&gt;
        &lt;ExtraDataItem name="GUI/GroupDefinitions/" value="m=254e0435-0f3f-445b-a35d-1f6d774a0fc3"/&gt;
        &lt;ExtraDataItem name="GUI/LastItemSelected" value="m=from_diag"/&gt;
        &lt;ExtraDataItem name="GUI/LastWindowPosition" value="255,217,770,550"/&gt;
        &lt;ExtraDataItem name="GUI/RecentFolderHD" value="//diag03-pc/vbox_hdd"/&gt;
        &lt;ExtraDataItem name="GUI/RecentListHD" value="\\diag03-pc\vbox_hdd\xp_legacy_mode.vdi"/&gt;
        &lt;ExtraDataItem name="GUI/SplitterSizes" value="255,510"/&gt;
        &lt;ExtraDataItem name="GUI/Toolbar/MachineTools/Order" value="None"/&gt;
        &lt;ExtraDataItem name="GUI/UpdateCheckCount" value="3"/&gt;
        &lt;ExtraDataItem name="GUI/UpdateDate" value="1 d, 2017-10-23, stable, 5.2.0"/&gt;
      &lt;/ExtraData&gt;
      &lt;MachineRegistry&gt;
        &lt;MachineEntry uuid="{254e0435-0f3f-445b-a35d-1f6d774a0fc3}" src="C:\Users\bogna\VirtualBox VMs\from_diag\from_diag.vbox"/&gt;
      &lt;/MachineRegistry&gt;
      &lt;NetserviceRegistry&gt;
        &lt;DHCPServers&gt;
          &lt;DHCPServer networkName="HostInterfaceNetworking-VirtualBox Host-Only Ethernet Adapter" IPAddress="192.168.56.100" networkMask="255.255.255.0" lowerIP="192.168.56.101" upperIP="192.168.56.254" enabled="1"/&gt;
        &lt;/DHCPServers&gt;
      &lt;/NetserviceRegistry&gt;
      &lt;SystemProperties defaultMachineFolder="C:\Users\bogna\VirtualBox VMs" defaultHardDiskFormat="VDI" VRDEAuthLibrary="VBoxAuth" webServiceAuthLibrary="VBoxAuth" LogHistoryCount="3" exclusiveHwVirt="false"/&gt;
      &lt;USBDeviceFilters/&gt;
    &lt;/Global&gt;
  &lt;/VirtualBox&gt;
  </code></pre>
  
  <p>How can I Get the uuid and src from MachineEntrys from this xml to an array?
  .net 4.5</p>
  
  <p>I tried it, becouse the array was empty:</p>
  
  <p>** DO NOT EDIT THIS FILE.
  ** If you make changes to this file while any VirtualBox related application
  ** is running, your changes will be overwritten later, without taking effect.
  ** Use VBoxManage or the VirtualBox Manager GUI to make changes.</p>
  
  <pre><code>        void getfromxml()
          {
  
              XmlDocument doc = new XmlDocument();
              doc.LoadXml(vboxxml);
  
  
              XmlNodeList nodes  = doc.DocumentElement.SelectNodes("/VirtualBox/Global/MachineRegistry/MachineEntry");
  
              int i = 0;
              foreach (XmlNode node in nodes)
              {
                  machines[i,0] = node.Attributes["uuid"].Value;
                  machines[i,1] = node.Attributes["src"].Value;
  
                  i++;
              }
  
  
  
          }
  </code></pre>