Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

EOutOfResources exception

138 views
Skip to first unread message

Mike Leahy

unread,
Mar 17, 2003, 9:05:52 PM3/17/03
to
Running my program in Delphi 5 I get...

Project Build17.exe raised exception class EOutOfResources with message
'RichEdit line insertion error'.

I'm searching for clues. Stepping through the code seems to show that the
RichEdit has 2 lines and is being asked to add 23 more. Of course, this is
after the exception was thrown so all bets are off.

What is an "Out Of Resources" error?


Kurt Barthelmess (TeamB)

unread,
Mar 18, 2003, 9:19:51 AM3/18/03
to
"Mike Leahy" <boo...@coil.com> wrote:

After sending a string to be added to the richedit, delphi checks to
see if it succeeded by checking the resulting caret position. (It
should be at the end of the new text.) If it isn't, you get that
exception.

You didn't mention the OS you are running, but unless it is one that
has unlimited resources, you may be getting caught there. Bottom line,
the richedit wasn't able to handle the additional lines you wanted to
add. But I doubt it happened at 23+2 lines, unless those were really
big lines.

Good luck.

Kurt

Mike Leahy

unread,
Mar 18, 2003, 1:17:29 PM3/18/03
to

"Kurt Barthelmess (TeamB)" <kbarth...@compuserve.com> wrote in message
news:3e772a12....@newsgroups.borland.com...

Thanks, Kurt. This confirms my suspicions that the RichEdit is getting
overloaded.

Any recommendation of a component that will take rich text beyond 65536
bytes on Win98 and higher?

Mike


Kurt Barthelmess (TeamB)

unread,
Mar 18, 2003, 5:21:49 PM3/18/03
to
"Mike Leahy" <boo...@coil.com> wrote:

>Thanks, Kurt. This confirms my suspicions that the RichEdit is getting
>overloaded.

But was it? With only 25 lines?

>Any recommendation of a component that will take rich text beyond 65536
>bytes on Win98 and higher?

First, confirm tnat a TRichEdit is so limited. I know the actual limit
for a TMemo is lower, but I thought a TRichEdit was better than 65K,
even on Win98.

Good luck.

Kurt

JH3

unread,
Mar 18, 2003, 8:43:35 PM3/18/03
to
Check for unwanted extra (esp. extended) characters after
the final bracket in the RTF encoding... I got that exact
same exception when loading in *very* small RTF's -- less
than 2K, in some cases -- because they had stuff like "2\ธๅด"
after them. (They were being read out of BLOBs, you see.)

Generally speaking I've always had the impression that
RichEdits are very picky about the code you throw at
them...

John H. Hedges


"Kurt Barthelmess (TeamB)" <kbarth...@compuserve.com> wrote in message

news:3e779b83....@newsgroups.borland.com...

0 new messages