I am trying to merge a Access recordset to a Word form field inserting a carriage return/line feed after each record. The merge performs correctly, except that an empty box appears in the Word formfield where the carriage return/ line feed should be. I am looping throug the recordset using the following code:
Do Until rs.EOF
strNames = strNames & rs("Names".Value & Chr(13) & Chr(10)
rs.MoveNext
Loop
I've tried using the vbCRLF constant, but get the same result. I also tried inserting ^p (the Word control character for carriage return) using Chr(94) & Chr(112), but that results in ^p being inserted as text rather than causing a carriage return as desired.
Any ideas?
Do Until rs.EOF
strNames = strNames & rs("Names".Value & Chr(13) & Chr(10)
rs.MoveNext
Loop
I've tried using the vbCRLF constant, but get the same result. I also tried inserting ^p (the Word control character for carriage return) using Chr(94) & Chr(112), but that results in ^p being inserted as text rather than causing a carriage return as desired.
Any ideas?