How can i read from xml file only the text line by line with date and time parse from the xml file?
<p>In this code im using InnerText to view only the text from the xml file without any tags.
But i want two things to change now:</p>

<pre><code>using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Xml;

namespace WindowsFormsApplication1
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            string xmlString = @"d:\adilipman1937067724.xml";

            XmlDocument doc = new XmlDocument();
            doc.Load(xmlString);
            string t = doc.InnerText;
            textBox1.Text = t;
        }
    }
}
</code></pre>

<ol>
<li><p>To parse the text to lines.</p></li>
<li><p>To parse and add to each line the date and time.</p></li>
</ol>

<p>Here is an example of the xml file i want to parse from:</p>

<pre><code>FriendlyName="adilipman@yahoo.com"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;testing the test.&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:15:58" DateTime="2012-01-31T08:15:58.897Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User 
</code></pre>

<p>Instead to put in a string only the text "testing the test" i want it to be format in the textBox1 like:</p>

<pre><code>adilipman 10:15:58 31/01/2012 testing the test      
</code></pre>

<p>This is a line.
Next line will be for example:</p>

<pre><code>adilipman 10:15:59 31/01/2012 testing the test was ok 
</code></pre>

<p>But now what im getting in the textBox1 is like this:</p>

<pre><code>testing the test testing the test was ok 
</code></pre>

<p>Some more text from the xml file:</p>

<pre><code>&lt;?xml version="1.0"?&gt;
&lt;?xml-stylesheet type='text/xsl' href='MessageLog.xsl'?&gt;
&lt;Log FirstSessionID="1" LastSessionID="2"&gt;&lt;Message Date="31/01/2012" Time="10:15:42" DateTime="2012-01-31T08:15:42.467Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User FriendlyName="adilipman@yahoo.com"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;היי&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:15:55" DateTime="2012-01-31T08:15:55.097Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User FriendlyName="adilipman@yahoo.com"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;הייתה לי בעיה עם התוכנת ברקים אבל עכשיו הכל עובד.&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:15:58" DateTime="2012-01-31T08:15:58.897Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User FriendlyName="adilipman@yahoo.com"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;מה השלב הבא ?&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:16:27" DateTime="2012-01-31T08:16:27.775Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User FriendlyName="adilipman@yahoo.com"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;אמרת לי בזמנו לחשב ממוצע של 1000 ערכים ? הכוונה 1000 ערכים בפריים ? כי בפריים יש 256 מספרים לא ?&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:17:03" DateTime="2012-01-31T08:17:03.405Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="adilipman@yahoo.com"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;לחשב ממוצע של 1000 הערכים הגבוהים ביותר בהיסטוגרמה&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:17:10" DateTime="2012-01-31T08:17:10.405Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="adilipman@yahoo.com"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;ז"א בפריים&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:17:14" DateTime="2012-01-31T08:17:14.135Z" SessionID="1"&gt;&lt;From&gt;&lt;User FriendlyName="adilipman@yahoo.com"/&gt;&lt;/From&gt;&lt;To&gt;&lt;User FriendlyName="Chocolade"/&gt;&lt;/To&gt;&lt;Text Style="font-family:Segoe UI; color:#000000; "&gt;לא בהיסטוגרמה&lt;/Text&gt;&lt;/Message&gt;&lt;Message Date="31/01/2012" Time="10:17:20" DateTime="2012-01-31T08:17:20.142Z" SessionID="1"&gt;&lt;From&gt;&lt;User 
</code></pre>
