Append text to RTF file

  • Thread starter Thread starter Deshi
  • Start date Start date
D

Deshi

Hi,.

I am trying to append text into the RTF file, nothing seems to be
working for me... here is the code

FileStream fs = new FileStream("c:\\djj.rtf", FileMode.Append,
FileAccess.Write);
StreamWriter sw = new StreamWriter(fs);
sw.WriteLine("Appending this text at the end of the file");
sw.Close();
fs.Close();

it works well with the normal text file but not for RTF, does anyone
know how to append text at the end of the RTF file..
 
Hi,.

I am trying to append text into the RTF file, nothing seems to be
working for me... here is the code

FileStream fs = new FileStream("c:\\djj.rtf", FileMode.Append,
FileAccess.Write);
StreamWriter sw = new StreamWriter(fs);
sw.WriteLine("Appending this text at the end of the file");
sw.Close();
fs.Close();

it works well with the normal text file but not for RTF, does anyone
know how to append text at the end of the RTF file..

Hi heshi

checkout this article

http://www.codeproject.com/KB/string/nrtftree.aspx

Munna
 
Back
Top