Counting num chars in real time

L

Luis

Hello.
I have a form with a memo field that i want to limit the
size of that field. I'd like to create a control on the
form that while the user is typing the text on that memo
field the length of the text is displayed on that control.
It's like some sites that allow us to send messages that
are counting the number of chars as we type the message.

Is this possible?

Thanks in advance.

Luis
 
K

Ken Snell

One way to do this would be to use the OnChange event of the textbox into
which the info is being typed:

Private Sub MemoTextbox_Change()
Me.CountingTextbox.Value = Len(Me.MemoTextbox.Text)
End Sub

Note in this situation that you do want to use the Text property of
MemoTextbox.
 
L

Luis

Worked perfectly!

Thanks.
-----Original Message-----
One way to do this would be to use the OnChange event of the textbox into
which the info is being typed:

Private Sub MemoTextbox_Change()
Me.CountingTextbox.Value = Len(Me.MemoTextbox.Text)
End Sub

Note in this situation that you do want to use the Text property of
MemoTextbox.

--
Ken Snell
<MS ACCESS MVP>




.
 

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