RTF control and Enter key

With RTF Control user must use CTRL-ENTER key to go to the next line!

is there anyway allow user to type normally?

What version of Clarion and the RTF control are you using?
Enter key inserts a new line for me in Clarion 9.1 and Clarion 10.

latest Clarion 10
10.0.0 Build 12799

1 Like

I tested with 12799 and it worked here.
You might need to post some additional details.
What does your RTF Text control definition look like? Are you using one of the RTF Control classes with it? If so, what initialization code is being done by the class.
Anything you think might be helpful.

I’ll try…

Not used RichText before - (well may have tried some years ago)
I have used 255 char text fields but need more now ie. 2048
Since text field can’t do more than 255 I tried RichText

I created a Window and simply dropped RTF Control set to Field
(don’t need status bar). I disabled the new button

Can’t see anything in properties/actions regarding the control!

I have use Default ABC: RTFControlClass ticked

Two points.

First, the standard text control can definitely take more than 255 characters. I would not use RTF unless your users need to format the text in the field.
Second, you should be able to use Enter to make new lines in either a regular or RTF control.
Try the attached example. It is in C 10.12799. It works here for me. It is a very simple ABC app with one window using a text control and another using the RTF Control template.
TextControlTest.zip (10.1 KB)

1 Like

ENTRY controls are limited to 255, but TEXT can go way higher. Last time I checked, they were limited to around 30K characters unless there were multiple TEXT controls on the same window, then the capacity seemed to drop.

If you actually want Rich Text, you need to give a very generous string size to handle all of the extra “stuff” in RTF.

Hi Jeff,
I’m not sure that is still true. I have a window in C9.1 with 3 RTF text controls and each of them are 200,000 characters in size.
I do have a confirmed PTSS report of a bug that doesn’t allow you to paste more characters into a text control after you have pasted around 6000 characters. However, if you close and reopen the window you can paste another 6000 characters.

1 Like

Looks like you’re right Rick. Not sure when that changed, but C10 is way better.

I just created a 2MB string and pasted that much into the TEXT control.


THANK YOU very much for your help.
The problem was caused by ABCFree DOSEnter template!

I selected Don’t generate Code and that’s sorted the ENTER Key problem.

In my dictionary, I have Notes and Comments fields set to 2048 & CString in most used tables
maybe I had experimented with a large text field. Good to know I don’t really need to use RTF to get large text box!! Unfortunatly, haven’t had time to use Clarion for about 2 years (well apart from a few minor fixes)

Anyway, sorted now & thanks for your help