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

return character in editbox

Status
Not open for further replies.

LindaRichard

Programmer
Feb 23, 2001
103
CA
I have a multi-line edit box and a grid that displays
the typed text. The problem is when the user includes
a return in the edit box the return appears as a square
character in the grid. When I browse the database
record the return is represented as a double vertical line
character.

Anybody have any suggestions on how to avoid these odd
characters being displayed? Is it something with my
vfp 7.0 setup?

Any suggestions appreciated.
Thanks
Linda
 
Try removing the linefeeds from the memofield.
You can do this with the command strtran(memofield, chr(10), "" )

hth,

Stefan
 
Thanks to both of you for answering my question.

Both the grid and textbox are currently set at arial.
Changing the font does make a change on what the character
looks like but there is still some odd character displayed
in the grid.

I set the textbox property addlinefeed to .f. so this
should take care of the linefeed problem. But I do
want the user to be able to use the return.


Could the problem be that it's a character field and not
a memo.

Thanks again for your help
Linda
 
Linda,

Stefan has got the right answer, except that you should also remove CHR(13). Also, I'd suggest you change these two characters to a single space rather than an empty string, otherwise the words will run together next time you display them in an edit box.

Mike


Mike Lewis
Edinburgh, Scotland

My Visual Foxpro web site: My Crystal Reports web site:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top