Board index » delphi » Add to memo field doesn't work

Add to memo field doesn't work

Hi,
I'm experiencing problems with this:
I have a memo field to which I add text using this code:

bblog.memo1.lines.add(IntToStr(bblog.memo1.lines.count + 1)
     + ': ' + s);

Usually no problem with that, but sometimes the add just doesn't work.
The program doesn't crash or anything but the add just doesn't add
anything. Anybody has any idea what could cause this and how I can
solve it?

Thanks,
Ronald

PS If you answer to this, please remove the nospam part from my email
address.

 

Re:Add to memo field doesn't work


Hi Ronald,

   It seems strange that the line just shouldn't work. Very strange. (I
fact I find it unbelievable.) Are you sure the line is being
executed??? Put a breakpoint on the line and check. Chances are it's
not being executed when you think it is.

Regards,
     Peter Williams  :)))

In article <39ede548.6303...@news.NL.net>,

Quote
  rlok...@nospam.yahoo.com wrote:
> Hi,
> I'm experiencing problems with this:
> I have a memo field to which I add text using this code:

> bblog.memo1.lines.add(IntToStr(bblog.memo1.lines.count + 1)
>      + ': ' + s);

> Usually no problem with that, but sometimes the add just doesn't work.
> The program doesn't crash or anything but the add just doesn't add
> anything. Anybody has any idea what could cause this and how I can
> solve it?

> Thanks,
> Ronald

> PS If you answer to this, please remove the nospam part from my email
> address.

Sent via Deja.com http://www.deja.com/
Before you buy.

Re:Add to memo field doesn't work


Apparently I wasn't clear enough ;-)
The problem is the statement works fine for about 600-800 times,
sometimes no problem at all. But it happens that suddenly the string
won't be added to the memo. The de{*word*81} executes the statement, but
in the memo nothing happens! I think it might have something to do
with memory settings?

Ronald

Quote
>Hi Ronald,

>   It seems strange that the line just shouldn't work. Very strange. (I
>fact I find it unbelievable.) Are you sure the line is being
>executed??? Put a breakpoint on the line and check. Chances are it's
>not being executed when you think it is.

>Regards,
>     Peter Williams  :)))

>In article <39ede548.6303...@news.NL.net>,
>  rlok...@nospam.yahoo.com wrote:
>> Hi,
>> I'm experiencing problems with this:
>> I have a memo field to which I add text using this code:

>> bblog.memo1.lines.add(IntToStr(bblog.memo1.lines.count + 1)
>>      + ': ' + s);

>> Usually no problem with that, but sometimes the add just doesn't work.
>> The program doesn't crash or anything but the add just doesn't add
>> anything. Anybody has any idea what could cause this and how I can
>> solve it?

>> Thanks,
>> Ronald

>> PS If you answer to this, please remove the nospam part from my email
>> address.

>Sent via Deja.com http://www.deja.com/
>Before you buy.

Re:Add to memo field doesn't work


Quote
"Ronald Lokers" <rlok...@nospam.yahoo.com> wrote in message news:39ee16fd.3478582@news.NL.net...
> Apparently I wasn't clear enough ;-)
> The problem is the statement works fine for about 600-800 times,
> sometimes no problem at all. But it happens that suddenly the string
> won't be added to the memo. The de{*word*81} executes the statement, but
> in the memo nothing happens! I think it might have something to do
> with memory settings?

> Ronald

Don't forget that a TMemo is limited to 32Kb in Windows 9x!

Other Threads