Delphi and Kylix

Moderators: pritaeas
Number of threads: 7264
Number of posts: 19073

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
New TStringGrid Posted by mero73 on 21 Oct 2003 at 5:30 AM
Hi All,
I want to create a new TStringGrid component witht a published property
-for ex. "Alias button index"- which will enable the user from entering the index of the grid column on which he wants to display a "..." button at.
I know I need to override the OnDrawCell event on the new component, but I don't know how to do so.

Can anyone help me with that please
Your co-operation is highly appreciated
Report
Re: New TStringGrid Posted by zibadian on 21 Oct 2003 at 5:53 AM
: Hi All,
: I want to create a new TStringGrid component witht a published property
: -for ex. "Alias button index"- which will enable the user from entering the index of the grid column on which he wants to display a "..." button at.
: I know I need to override the OnDrawCell event on the new component, but I don't know how to do so.
:
: Can anyone help me with that please
: Your co-operation is highly appreciated
:
Best is not to override the OnDrawCell itself, because that will not allow other programmers to use the event. You need to override the DrawCell() method instead. This will in turn call the OnDrawCell event to allow other programmers to change the appearance if they wish.



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.