I am in the middle of writing a form which takes a description of a product and saves it to a memo field in Access. However if this description has two or more paragraphs before it is saved to the databse, when it comes out again, it has lost the paragraphs and is just one lump of text.
Does anyone know how you go about retaining the structure of the text? Does the code have to check for paragrapgh and instert the <p> tags?
Thank you in davance for any tip you may have.You can do two things, put the paragraph in an asp:textbox / textarea, or surround the paragraph with <pre></pre>, which tells the browser not to mess with the formatting.
Thanks Michael your help is much appreciated.
Simple when you know how!
Hi,
You may use strMemo.Replace( Environment.NewLine, "<br>" )
0 comments:
Post a Comment