Character Count on a Form

123James

Registered User.
Local time
Yesterday, 18:29
Joined
May 15, 2006
Messages
60
hello

I have searched the forum for character and word count tools that can be added onto forms but have only found an example that is too complicated for me.

Can anyone tell me of a simple way to, on a form, display next to a memo field how many characters (including spaces) have been entered?

All suggestions appreciated...
James
 
trim(len(me!myMemoName)) would probally give you the answer you require
 
Thanks for the reply, should I just enter this into the ControlSource of a text box dragged onto the same form as the memo field??
 
Put an unbound text box on the same form as the memo field and in the memo field's

On Change event put
Code:
Me.MyMemoCountTextBoxNameHere = Len(Me.MyMemoName.Text)
If you use trim as Dennisk suggests then it will ignore spaces at the end, but you specifically stated you wanted spaces included. Also, if you use Me.myMemoName as he suggests it won't give you the total until the after update of the control.
 
Thanks for the reply bob.

I copied the code into the On Change event and edited the names to match my text box and memo field but keep getting an error message...

"Microsoft can't find the macro Me."

I also tried the code in the After Update event but no luck!

any ideas??
 
Sorry about not replying but only just got back to work this morning!

I managed to find a simple sample of the character count that I have edited and this works fine.

thanks anyways
James
 

Users who are viewing this thread

Back
Top Bottom