473,386 Members | 1,699 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

StreamWriter and formatting

i have a richtextbox control containing text with bold and various font formatting.
when i write to a text file or Word document using streamwriter, all the formatting is lost. how do i preserve the original formatting???
thanks.

Nov 16 '05 #1
2 5195
Try using "SaveFile" method of the richtext control
eg: rtc.SaveFile("filename.doc",RichTextBoxStreamType. RichText);

"subT" wrote:
i have a richtextbox control containing text with bold and various font formatting.
when i write to a text file or Word document using streamwriter, all the formatting is lost. how do i preserve the original formatting???
thanks.

Nov 16 '05 #2
thanks man, works fine.

"Sree" wrote:
Try using "SaveFile" method of the richtext control
eg: rtc.SaveFile("filename.doc",RichTextBoxStreamType. RichText);

"subT" wrote:
i have a richtextbox control containing text with bold and various font formatting.
when i write to a text file or Word document using streamwriter, all the formatting is lost. how do i preserve the original formatting???
thanks.

Nov 16 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Vladimir Bezugliy | last post by:
I have a server that listen a socket. And I have next client: TcpClient socketForServer = new TcpClient("IVBEZUGLIY", 21000); NetworkStream networkStream = socketForServer.GetStream();...
4
by: Majed | last post by:
Hi , all I'm trying to write unicode to a file for another app (not developed with vs2003) to read it. I used StreamWriter with unicode encoding.but I was surprised that the streamwriter adds FFFE...
9
by: ShadowOfTheBeast | last post by:
Hi, I have got a major headache understanding streamReader and streamWriter relationship. I know how to use the streamreader and streamwriter independently. but how do you write out using the...
4
by: rex64 | last post by:
I am getting an error message and I have not been able to figure hot how to fix it. I have done some research with no answers yet. I found this code that may help? Not sure what to do with it....
10
by: Oscar Thornell | last post by:
Hi, I generate and temporary saves a text file to disk. Later I upload this file to Microsoft MapPoint (not so important). The file needs to be in UTF-8 encoding and I explicitly use the...
2
by: Larry | last post by:
if I type in the return character in a text box or richtext box, I do not see the newline character in a string. Scenario - I type 2 paragraphs in a text box. Visibly I can see the information...
24
by: =?Utf-8?B?RHVja3dvbg==?= | last post by:
Hello, My code is suppose to write to an existing file. But after my C# code appends the file, the previous text loses all the endline characters, becoming one long line. How can I retain the...
5
by: Rob | last post by:
Hi, I have a VB.Net application that parses an HTML file. This file was an MS Word document that was saved as web page. My application removes all unnecessary code generated by MS Word and does...
2
by: Eric | last post by:
Hi, i'm experientating with object StreamWriter in asp.net. This code works: the string is written to an excel sheet, but i have a questions about it: how does asp.net know the string must be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.