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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Text Formatting Problem

Status
Not open for further replies.

SteelDragon

Programmer
Feb 1, 2001
134
US
I have a text formatting problem I need some assistance with. I am trying to bring over a large text field from an SQL database, and I want the data to retain most of it's original formatting. The data is from a CRM software package, and the text is formatted in paragraphs. The problem I have is two fold. 1) When I use HTML table to bring over and format the text it comes over as one big block,I need to retain the paragraph form. 2) When I use CFTable to bring over and format the text it retains it's paragraph from, but it does not wrap the text at the end of the screen, it gets truncated at whatever point I set my lines to. I need a happy medium. I need to find a way to bring over the text while retaining the paragraph form, and wrapping the lines when they are too long. If anyone can help me I would greatly appreciate it.

Thanks ahead of time,
SteelDragon
 
You could use the replace() function to replace #chr(13)##chr(10)# sequences to &quot;<br>&quot; which will give you an accurate rendering of the original formatting in an html table. The only difference between this and using the paragraphformat() function is that it changes single line feeds into spaces instead of a &quot;<br>&quot;.

Hope this helps,
GJ
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top