Castaway
02-27-2001, 07:22 AM
Is there a way to limit a Memo box. Where if I want the Memo box to stop at 1500 characters and just stop typing like a text box, which limits you to 255 characters.
Thanks
Thanks
|
View Full Version : Limit a Memo Box Castaway 02-27-2001, 07:22 AM Is there a way to limit a Memo box. Where if I want the Memo box to stop at 1500 characters and just stop typing like a text box, which limits you to 255 characters. Thanks Atomic Shrimp 02-27-2001, 12:40 PM I've not had a chance to test this, but I think in theory, you could add some code like: If Len(Me.TextBox) >1500 Then Me.TextBox = Left(Me.TextBox, 1500) MsgBox "You cannot enter any more data here" End If to maybe the OnChange or OnKeyPress event of the text box, I'm not sure if it will work, but it's an approach that might be worth a try, although the code will be executed on each keypress in that text box, so it might make typing a bit painful. Mike Castaway 03-05-2001, 12:41 PM Thanks.. I tried that but is there any other way of doing that. |