Groups > Borland > Borland Turbo C plus plus > Re: How to add column headings to TStringGrid????




How to add column headings to TStringGrid????

How to add column headings to TStringGrid????
Mon, 26 Mar 2007 23:04:40 -070
Hey all,
     Using Turbo C++ to build a demo app.  I have a TStringGrid in a tab 
sheet.  I can control the # of rows & cols, but I want to put column 
headings.  How do I do that?  There aren't properties in the Object 
Properties tab (to the left) that will let me do that?  I know 
TStringGrid has COLS & ROWS properties which is the headings I'm looking 
for, but I can't get access to them?  Note, I;m not trying to generate 
source--just want to keep it at the RAD interface right now...

thanks

Post Reply
Re: How to add column headings to TStringGrid????
Tue, 01 May 2007 21:17:39 -070
Angel2007 wrote:
> Hey all,
>     Using Turbo C++ to build a demo app.  I have a TStringGrid in a tab 
> sheet.  I can control the # of rows & cols, but I want to put column 
> headings.  How do I do that?  There aren't properties in the Object 
> Properties tab (to the left) that will let me do that?  I know 
> TStringGrid has COLS & ROWS properties which is the headings I'm
looking 
> for, but I can't get access to them?  Note, I;m not trying to generate 
> source--just want to keep it at the RAD interface right now...
> 
> thanks
> 
> angel
Hey Angel, since no one seems to know, here's the answer:

StringGrid1->Rows[0]->CommaText = "\"Column
1\",\"Column 2\",Column 
3,Column 4";

Post Reply
about | contact