public void ReadFile()
        {
            FileInfo file = new FileInfo(FileName);
            StreamReader rdr = file.OpenText();
            string fileContents = rdr.ReadToEnd();
            rdr.Dispose();

            FormatReader formatReader = new FormatReader();
            MessageBody = formatReader.GetMessageBody(fileContents);
        }
示例#2
0
        public void ReadFile()
        {
            FileInfo     file         = new FileInfo(FileName);
            StreamReader rdr          = file.OpenText();
            string       fileContents = rdr.ReadToEnd();

            rdr.Dispose();

            FormatReader formatReader = new FormatReader();

            MessageBody = formatReader.GetMessageBody(fileContents);
        }