Hello Sergey
In the Line Table1.cells[table1.RowCount-1,0].SetItemText(0,'Hello');
I need to force Aligning the word 'Hello' horizontally at the center of the Cell. How to do that???
Thank you in advance
Selecting A cell in a table
-
- Site Admin
- Posts: 17553
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
Re: Selecting A cell in a table
In TRichView, horizontal alignment in cell is defined just like in normal document: in paragraph properties.
To center text, its paragraph must have property Alignment = rvaCenter.
You can call
Cell.Clear;
Cell.AddNL('Hello', 0, ParaNo);
where ParaNo is an index (in RVStyle.ParaStyles[]) of item having Alignment = rvaCenter.
To center text, its paragraph must have property Alignment = rvaCenter.
You can call
Cell.Clear;
Cell.AddNL('Hello', 0, ParaNo);
where ParaNo is an index (in RVStyle.ParaStyles[]) of item having Alignment = rvaCenter.