Please help with count in a memofield

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi!!
I have this code there count how many vbCrLf there are
in my memofield, But if my user just write witout using
a new line, then there auto will come a newline when the
characters come to the end of the menofield , is there a way
to count this lines too ?
like if the last characters in the line is not a vbCrLf
then count this as a line.

Regards

Alvin
 
AFAIK, if the user doesn't initiate a new line, then there is no new line.
what you are seeing is the automatic line wrap in form view. if you widen
the control bound to the memo field, in design view, and then go back to
form view, you'll see that more of the text goes on the first line, and then
wraps to the second line and then to the third line, etc. however, if a new
line is initiated by the user, then the text moves to the new line
regardless of the size of the control that displays it.

hth
 
Hi Tina
yes i know that
i use this memofield on a asp page and i make the width off this
memo field to fit to the asp page, on my page i can have
maybe 30 lines, so i want to count all lines
hope you understand ........
What is the code for space ??
then i can use this to count the space
to the right for each lines......

regards

alvin
 
What is the code for space ??

Hex 20 (Decimal 32)
then i can use this to count the space
to the right for each lines......

Ummm... no, you can't. The display algorithm doesn't work by padding
the line with spaces, but by inserting carriage-return new-line pairs.

John W. Vinson[MVP]
 
Back
Top