using System;
using System.IO;

public class FileClass
{
    public static void Main() 
    {
        string path = @"c:\......\tagfile.txt";
        string message = field1.text;
        string S;
        try 
        {
            if (File.Exists(path)) 
            {
              static void ReadFromFile(path)
              {
                StreamReader SR;
                SR=File.OpenText(path);
                S=SR.ReadLine();
                while(S!=null)
              {
                S=SR.ReadLine();
              }
              SR.Close();
              }
              
              static void WriteToFile()
              {
                using (StreamWriter SW = File.CreateText(path)) {}
                SW.WriteLine(message);
                SW.Write(S);
                SW.Close();
              }
            } 
            else 
            {
                Console.WriteLine("The tagboard is empty.");
            }
        } 
        catch 
        {
            Console.WriteLine("An error occured writing you tag.");
        }
    }
}