View Single Post
  #4   Report Post  
Posted to microsoft.public.word.docmanagement
PRedd
 
Posts: n/a
Default Word 2000, 2003, XP Question

Steven

I have discovered that if you replace the CHR(13) with a ^l (that a lower
case letter L) then it should introduce a manual line break which formats
correctly in a table or outside the table. Would you be able to preprocess
the string returned from your database prior to putting it into your word
table?

Hope this helps

Paul




"StevenB" wrote:

Cindy,

Thank you very much for responding. The data is retrieved from an SQL view
and is placed in the template by vb code. The CR-LF already exist in the SQL
fields. Word 97 seems to interpret the CR-LF correctly and formats
accordingly. Unfortunately Word 2000 and subsequent versions do not. I hope
this answered your question and you can then give me some advice.

Steven

"Cindy M -WordMVP-" wrote:

Hi ?B?U3RldmVuQg==?=,

We have an application that uses Word 97. This app takes data from an SQL
2000 databse and inserts it into Word tables using SQL views. This works fine
using Word 97. When we attempt to use Word 2000, 2003 or XP the insertion
works but if the text is multi-lined and contains CR- LF charcters, they
appear as square hollow boxes and the text all appears on one line. We would
really like to move up to later versions of Word but this problem prevents
this. Anyone have any ideas how we can resolve this issue?

Difficult to give you an answer, since you don't detail how the data is put into
Word. Generally, though, word doesn't like CR-LF. If this is programming code,
try using vbCR (Chr$(13)) for new paragraphs. The same should work for Word 97,
so that you can continue to use the same code for all Word versions.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or reply
in the newsgroup and not by e-mail :-)