Web forum is in read-only mode. Login as active registered customer for write access
  Forum Search   New Posts New Posts

FNC Grid - How to make the header row span 2 lines

 Post Reply Post Reply
Author
Maierhofer Bernd View Drop Down
Senior Member
Senior Member
Avatar

Joined: 18 Oct 2015
Posts: 108
Post Options Post Options   Quote Maierhofer Bernd Quote  Post ReplyReply Direct Link To This Post Topic: FNC Grid - How to make the header row span 2 lines
    Posted: 10 Oct 2019 at 4:32pm
I?d like to have the header of my grid span two lines, while the rest of the grid is one-lined.

How do I achive this?

Thanks!
Back to Top
Bruno Fierens View Drop Down
TMS Support
TMS Support
Avatar

Joined: 11 May 2010
Posts: 8339
Post Options Post Options   Quote Bruno Fierens Quote  Post ReplyReply Direct Link To This Post Posted: 10 Oct 2019 at 8:36pm
I assume you refer to cell merging?
Did you check grid.MergeCells()?
Back to Top
Maierhofer Bernd View Drop Down
Senior Member
Senior Member
Avatar

Joined: 18 Oct 2015
Posts: 108
Post Options Post Options   Quote Maierhofer Bernd Quote  Post ReplyReply Direct Link To This Post Posted: 11 Oct 2019 at 12:11pm
Not really. Given, that the Header info for a column is lengthy, I would like to have two lines within the cells of the top (Header) row: e.g. "Room temperature<br>(average in ?C)".

Should I merge cells 1 and two of col 1, col 2 and so on?
Both rows must be fixed and actual data starts in row 3?

Do you have an example?
Back to Top
Bruno Fierens View Drop Down
TMS Support
TMS Support
Avatar

Joined: 11 May 2010
Posts: 8339
Post Options Post Options   Quote Bruno Fierens Quote  Post ReplyReply Direct Link To This Post Posted: 11 Oct 2019 at 3:23pm
Enable wordwrap and increase the row height

Example:
  TMSFNCGrid1.Columns[1].WordWrap := true;
  TMSFNCGrid1.RowHeights[0] := 64;
  TMSFNCGrid1.Cells[1,0] := 'line 1'#13'line 2';

Back to Top
Maierhofer Bernd View Drop Down
Senior Member
Senior Member
Avatar

Joined: 18 Oct 2015
Posts: 108
Post Options Post Options   Quote Maierhofer Bernd Quote  Post ReplyReply Direct Link To This Post Posted: 16 Oct 2019 at 6:59pm
Tx for this one. However, the drop down icon for filtering still has the normal size. Any chance to make the drop down the height of the row?
Back to Top
Bruno Fierens View Drop Down
TMS Support
TMS Support
Avatar

Joined: 11 May 2010
Posts: 8339
Post Options Post Options   Quote Bruno Fierens Quote  Post ReplyReply Direct Link To This Post Posted: 17 Oct 2019 at 10:08pm
This will require an adaption in the component. We will discuss & consider this here as it is unsure if one typically expects this to match the size of a combobox dropdown button or the height of the grid row.
Back to Top
Maierhofer Bernd View Drop Down
Senior Member
Senior Member
Avatar

Joined: 18 Oct 2015
Posts: 108
Post Options Post Options   Quote Maierhofer Bernd Quote  Post ReplyReply Direct Link To This Post Posted: 18 Oct 2019 at 10:24am
No problem, just looks a bit lost in the middle of the row.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down