This is what I'm doing:
I have two TMemos, Memo1 and Memo2
Memo1 is filled with information
I use the command Memo2->Lines->Add to add only a few lines of Memo1
The problem is that every time I add the lines to Memo2 there is a blank empty line at the end of Memo2 (that I didn't add)
So I try the command:
Memo2->Lines->Delete(Memo2->Lines->Count);
And nothing happens, but if I run:
Memo2->Lines->Delete(Memo2->Lines->Count - 1);
It removes the second to the last line.
(the line that has my data on it)
~
Heres an example of the data I'm working with:
~
Memo1:
Line 1
Line 2
Line 3
Line 4
Then I use the Add command to fill Memo2 like this:
Line 1
Line 3
<-- Undesired Empty Line
The problem is that its adding a line return and I can't get rid of it!
If you can shed some light on this please do, I don't know why the delete command isn't removing that last line.
I have two TMemos, Memo1 and Memo2
Memo1 is filled with information
I use the command Memo2->Lines->Add to add only a few lines of Memo1
The problem is that every time I add the lines to Memo2 there is a blank empty line at the end of Memo2 (that I didn't add)
So I try the command:
Memo2->Lines->Delete(Memo2->Lines->Count);
And nothing happens, but if I run:
Memo2->Lines->Delete(Memo2->Lines->Count - 1);
It removes the second to the last line.
(the line that has my data on it)
~
Heres an example of the data I'm working with:
~
Memo1:
Line 1
Line 2
Line 3
Line 4
Then I use the Add command to fill Memo2 like this:
Line 1
Line 3
<-- Undesired Empty Line
The problem is that its adding a line return and I can't get rid of it!
If you can shed some light on this please do, I don't know why the delete command isn't removing that last line.