Page 1 of 1
Loading text in columns
Posted: Wed Mar 28, 2007 3:35 pm
by rvu
Hello
I want to load a file (txt, rtf) into 2 columns in the TRichViewEdit component.
What is the method for doing this ?
Thanks
Posted: Wed Mar 28, 2007 4:03 pm
by Sergey Tkachenko
Only separating it in two pieces and loading in table with 2 columns
Posted: Wed Mar 28, 2007 4:12 pm
by rvu
Hello
I created a table Like this :
Code: Select all
Tbl := TRvTableItemInfo.CreateEx(1,2,RichView1.RVData);
RichView1.AddItem('table', Tbl);
RichView1.Format;
then I loaded a text file into the first column like this :
Code: Select all
if OpenDialog1.Execute then
begin
tbl.Cells[0,0].LoadText(OpenDialog1.FileName,0,0,True);
RichView1.Format;
end;
But the text only flows in the first column and not the second. I want the text to automatically flow into the second column after it has filled the 1st column.
What i really want to do is :
The amount of text that fits in the 1st column of the RichView1 control should be considered as 1 page and the next page in column 2 and so on.
So that when i scroll, both columns will load odd and even page numbers.
Is this possible ? Can you please show a way ?
Thanks a lot for help.
Posted: Wed Mar 28, 2007 5:27 pm
by Sergey Tkachenko
No. It's not possible, it's a table, not real columns.
Columns are not supported yet.
You can print document in two columns using TRVReportHelper, though
Posted: Wed Mar 28, 2007 5:58 pm
by rvu
Thank you Sergey