Conveting hard return in memo field

B

Bob Smith

I have a linked table to sql server that uses the text
datatype and in that field it has stored hard
returns throughout text. When bringing them into access
via a query they show up as a square character. Access is
not recognizing them as a hard return and I need it to. I
have tried to do a replace(field,chr(13),chr(xx)) and it
works when I replace it with a letter, but can't seem to
get a hard return. Any help would be appreciated
 
F

fredg

I have a linked table to sql server that uses the text
datatype and in that field it has stored hard
returns throughout text. When bringing them into access
via a query they show up as a square character. Access is
not recognizing them as a hard return and I need it to. I
have tried to do a replace(field,chr(13),chr(xx)) and it
works when I replace it with a letter, but can't seem to
get a hard return. Any help would be appreciated

In Access, a hard return is chr(13) & chr(10) in that order.

If the return character in the field is chr(13) use:

Replace([MemoField,chr(13),chr(13) & chr(10))
 
G

Guest

Thanks Fred, exactly what I needed worked like a charm!!!!

-----Original Message-----
I have a linked table to sql server that uses the text
datatype and in that field it has stored hard
returns throughout text. When bringing them into access
via a query they show up as a square character. Access is
not recognizing them as a hard return and I need it to. I
have tried to do a replace(field,chr(13),chr(xx)) and it
works when I replace it with a letter, but can't seem to
get a hard return. Any help would be appreciated

In Access, a hard return is chr(13) & chr(10) in that order.

If the return character in the field is chr(13) use:

Replace([MemoField,chr(13),chr(13) & chr(10))

--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top