Fabio,
>But if EditBox.ReadOnly is True this not occur
>( because into the internal C++ code the readonly is checked before the ENTER )
Pressing Enter (or any other keypress that would serve to change the value) inside a readonly editbox is always results in a keypress not allowed beep and the keypress is consumed by the control. The height of the editbox has nothing to do with it. You can verify this for yourself by adding this code to your test:
ADD OBJECT edit3 AS editbox WITH ;
Left = 142, ;
Top = 80, ;
ReadOnly = .T., ;
Value = "CCCC"
>If you use a EditBox with a single single line
>VFP it interprets the text like a single line text.
>( a very usefull behaviour but not completed, UP/DOWN ... they lack )
>
>Result: the ENTER not split the text ,
>but it lose the editbox focus and jump into the next control on tab list.
I'm not sure I'd expect an editbox shorter than 2 * sysmetric(6) to work very well at all. Just use a textbox for single lines of input where carriage returns and multiple lines are not required.