Here is my code:

```
 static void main(string[] args)
    {
        XmlDocument xmldoc = new XmlDocument();
        xmldoc.Load("data.XML");
        XmlNodeList userNodes = xmldoc.SelectNodes("data.XML");
        foreach (XmlNode userNode in userNodes) ;

    }

    private string id;
    private string APIkey;
    private string VCode;

    public string ID
    {
         get { return id; }
         set { id = Guid.NewGuid().ToString(); }
    }

    public string APIKEY
    {
        get { return APIkey; }
        set { APIkey = value; }
    }

    public string VCODE
    {
        get { return VCode; }
        set { VCode = value; }

    }

    public static void SaveData(object obj, string Filename)
    {

        XmlSerializer sr = new XmlSerializer(obj.GetType());
        TextWriter writer = new StreamWriter(Filename, true);
        sr.Serialize(writer, obj);
        writer.Close();

    }
}

```

Here is my button;

```
    private void button1_Click(object sender, EventArgs e)
   {
    {
       try
    {

        APISAVE info = new APISAVE();
        info.APIKEY = txtAPI.Text;
        info.VCODE = txtVerC.Text;
        info.ID = info.ID;
        APISAVE.SaveData(info, "data.XML");

    }

    catch (Exception ex)

    {
        MessageBox.Show(ex.Message);
    }
}

```

ok what i want to do is add what i type in the text boxes to go into the XML file BUT when i do it again it'll add it to the XML not overwrite it. 

i've been googling for awhile and reading lots of bits and it's just not making any sense, i've tried. im now asking for a good hearted soul to please explain to me in baby language were it's all going wrong. 

EDIT 

XML OUTPUT;

```
<?xml version="1.0" encoding="utf-8"?>
<Serialization xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"  xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<ID>91bb44be-d55e-40f6-83f7-8fb43d0a7321</ID>
<APIKEY>12</APIKEY>
<VCODE>12</VCODE>
</Serialization><?xml version="1.0" encoding="utf-8"?>
<Serialization xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<ID>c2a45a36-e7c8-4ac5-a37c-87c452db5807</ID>
<APIKEY>123</APIKEY>
<VCODE>123</VCODE>
 </Serialization>

```

Another Edit: 

```
using System;
using System.Collections.Generic;
using System.Windows.Forms;
using System.Xml;
using System.Xml.Linq;
using System.Xml.Serialization;
using No_IdeaV2.API_Key_Window;
using System.IO;

namespace No_IdeaV2.API_Key_Window
{
public partial class UCAPIn : Form
{        
    public UCAPIn()
    {
        InitializeComponent();
    }

    private void label1_Click(object sender, EventArgs e)
    {
    }

    private void menuStrip1_ItemClicked(object sender,  ToolStripItemClickedEventArgs e)
    {

    }

    private void whatAmIDoingToolStripMenuItem_Click(object sender, EventArgs e)
    {

    }

    private void textBox1_TextChanged(object sender, EventArgs e)
    {

    }

    public List<Serialization> list = null;
    private void UCAPIn_Load(object sender, EventArgs e)
    {
        list = new List<Serialization>();
        var doc = XDocument.Load("data.XML");

        foreach (XElement element in doc.Descendants("Serialization"))
        {
            list.Add(new Serialization()
            { ID = element.Element("ID").Value, APIKEY = element.Element("APIKEY").Value, VCODE = element.Element("VCODE").Value });
        }
    }

    public void button1_Click(object sender, EventArgs e)
    {
        {
            try
            {
                Serialization info = new Serialization();
                info.APIKEY = txtAPI.Text;
                info.VCODE = txtVerC.Text;
                info.ID = Guid.NewGuid().ToString();
                list.Add(info);
                Serialization.SaveData(list, "data.XML");

            }

            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
    }

    private void button2_Click(object sender, EventArgs e)
    {
        this.Close();
    }

    private void whatIsThisToolStripMenuItem_Click(object sender, EventArgs e)
    {

    }

        public class Serialization
    {
        private string id;
        private string APIkey;
        private string VCode;

        public string ID
        {
            get { return id; }
            set { id = value; }
        }

        public string APIKEY
        {
            get { return APIkey; }
            set { APIkey = value; }
        }

        public string VCODE
        {
            get { return VCode; }
            set { VCode = value; }

        }

        public static void SaveData(List<Serialization> list, string      Filename)
        {
            XmlSerializer sr = new XmlSerializer(list.GetType());
            TextWriter writer = new StreamWriter(Filename, true);
            sr.Serialize(writer, list);
            writer.Close();
        }
    }

}

```

}