CRDBGrid - Column Width & Horiz. Scroll

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
MFaust_2000
Posts: 1
Joined: Wed 30 Jul 2014 16:00

CRDBGrid - Column Width & Horiz. Scroll

Post by MFaust_2000 » Wed 30 Jul 2014 16:11

I'm having a challenge with the CRDBGrid and what it allows for the column sizes. Is there a maximum width for the grid itself? If I change the component to Alignment=AlNone, i'm able to have a really wide grid. If I change it to AlClient, the Grid itself has a maximum size of 911 and I'm unable to increase the individual column widths.

Second question, how do I get the horizontal scroll bar to display.

Thanks in advance for your help!

ViktorV
Devart Team
Posts: 2299
Joined: Wed 30 Jul 2014 07:16

Re: CRDBGrid - Column Width & Horiz. Scroll

Post by ViktorV » Fri 01 Aug 2014 13:13

To get the horizontal scrollbar displayed, you can change the Resize method in the CRGrid source code.
Add the following line:
ShowScrollBar(Handle, SB_HORZ, true);

I can not reproduce the problem with column width. If the dgeStretch option is not set in the TCRGrid.OptionsEx property, I can change column width without restrictions. Try to compose a small sample to demonstrate the problem and send it to viktorv*devart*com.

Post Reply