Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How can I keep the propertoes of a .rtf line

Status
Not open for further replies.

iara

Programmer
Oct 2, 2002
17
HN
Hi,
I have read line by line and have search for a particular word using regex, when it has found this word i have sent this line to a function because i want to read this particular line by each character. My question is the file is in .rtf, how can y keep the format of this particular line? Its just sending a bunch of text characters.
well Is there a better way for me to do this ?
any suggestions?




 
This is my code
{
//READ A LINE
String scfile=dlgOpen.FileName;
StreamReader srReadline=new StreamReader ((System.IO.Stream )File.OpenRead(scfile),System.Text.Encoding.ASCII );
srReadline.BaseStream.Seek (0,SeekOrigin.Begin );
while(srReadline.Peek () > -1)
rtb_try.Rtf =srReadline.ReadLine() ;

srReadline.Close();
}
If you know a way of keeping the properties it would be alot of help..
thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top