Hi,
i need to draw custom textafter in TnxTextColumn or add Col,Row in OnGetDrawText.
Because i have grid with values and after value need to show units. User can edit only value so TextAfter is great but now is same for all rows. I need this:
5 [kg]
7 [kg]
25 [ml]
147.5 [ml]
47 [kg]
etc.
OnGetDrawText i can't use because i don't know which fields is requested (no col, row info)
TextAfter is same for all rows.
So, is possible do that with NextGrid ?

Grid custom TextAfter/TextBefore on rows
Started by jsvaton, Apr 20 2014 01:33 AM
grid textafter textbefore custom
3 replies to this topic
#1
Posted 20 April 2014 - 01:33 AM
#2
Posted 21 April 2014 - 07:32 PM
Hm,
It seems that I will need to add property like PaintingCell : TPoint so you can identify currently painting cell.
In v6 I have already added ACol and ARow in OnGetText, but for v5 I will need to add this property.
I will add it now. I will release new update today/tomorrow.
It seems that I will need to add property like PaintingCell : TPoint so you can identify currently painting cell.
In v6 I have already added ACol and ARow in OnGetText, but for v5 I will need to add this property.
I will add it now. I will release new update today/tomorrow.
boki@bergsoft.net | LinkedIn Profile
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.
#3
Posted 21 April 2014 - 07:40 PM
PS. Added:
procedure TForm1.NxNumberColumn1GetDrawText(Sender: TObject; var Text: WideString); begin case NextGrid1.PaintingCell.Y of 0: Text := Text + ' $'; 1: Text := Text + ' eur'; end; end;
boki@bergsoft.net | LinkedIn Profile
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.
#4
Posted 22 April 2014 - 12:10 AM
Thank you very much. Work OK

Also tagged with one or more of these keywords: grid, textafter, textbefore, custom
Announcements →
Announcements →
Nextsuite v6.30.0 releasedStarted by Boki (Berg), 10 Jul 2024 ![]() |
|
![]() |
||
NextSuite v5 - VCL Components (Previous version) →
Next Editors →
Problem with TNxEdit and TextAfterStarted by m610, 10 Mar 2016 ![]() |
|
![]() |
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users