A minor, but useful, difference between LBB and LB 4.04 is that you can use the ES_WANTRETURN stylebit to enable the Return (Enter) key in a TEXTBOX:
Code: nomainwin
textbox #w.tb, 2, 0, 300, 320
stylebits #w.tb, _WS_VSCROLL OR _ES_MULTILINE OR _ES_WANTRETURN, 0, 0, 0
open "Return key in a Textbox" for window as #w
#w "trapclose quit"
#w.tb "Type some text and try the Return key."
wait
sub quit handle$
close #handle$
end
end sub
This works in many respects like a TEXTEDITOR, except that the Tab key moves focus to the next control rather than performing a tabulation function.
It's rather odd that you can't use the same trick in LB 4.04. As far as I know a TEXTBOX is just a regular Windows Edit Control (as it is in LBB), but for some reason in LB it doesn't respond to the ES_WANTRETURN stylebit as you would expect.
Richard.