OnMaxText - cTextEdit
Fires when maximum text size is exceeded
Type: Event
Syntax
Procedure OnMaxText
Description
Fires when the maximum text size the control can contain is exceeded.
The default maximum number of characters for the control is 64 KB (65536 bytes or characters). piMaxChars sets or returns maximum number of characters.
| Col 1 | Col 2 |
|---|---|
| Note: | piMaxChars determines the maximum number of visible characters the user can enter into the control. However, when getting the value or saving the value to a database field, the value will contain additional non-visible characters. Each time the user presses Enter or Shift+Enter to break the line, this will be counted as a single visible character, but the value will contain 2 characters, a linefeed character (ASCII 10) followed by a carriage return character (ASCII 13). |
Sample
This sample displays a message box with a warning to the user when the maximum text size is exceeded.
Procedure OnMaxText
send Stop_Box "You have exceeded that maximum text this control can hold." "Warning"
End_Procedure // OnMaxText