StringGrid scrollbars not visible with DefaultDrawing set to false

Roger Alcindor
Roger Alcindor used Ask the Experts™
on
I am writing a Windows 32 application that uses a VCL StringGrid component using Embarcadero C++ Builder XE2.
I have set the StringGrid component DefaultDrawing property to false and the string grid is displaying its data using code placed in the OnDrawCell event handler.
For conditions when the number of rows in the string grid exceed the available space in the screen grid, I need to use a vertical scroll bar to allow navigation to "off screen" data rows. I have set the ScrollBars property in the StringGrid to ssVertical but no scroll bar appears and "off screen" data cannot be viewed.
How do I get vertical scroll bars in this situation, bearing in mind that I am using C++ Builder ?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Oracle dba
Top Expert 2009
Commented:
Almost the first thing i do after installing Delphi is look for better components
The stringgrid is a very very basic grid.

You can fix issues in it, but you'll find you'll be repeating yourself in fixing a miriad of problems in it.
with google you'll find a lot of fixes
http://www.delphipages.com/forum/showthread.php?t=120690
http://www.experts-exchange.com/Programming/Languages/Pascal/Delphi/Q_21341441.html

I would check out tory for better alternatives
http://torry.net/pages.php?id=114

if you have the budget, there is some very good grids like the quantumgrid
it'll save you a lot of time too

Author

Commented:
Very useful information.
In fact the problem turned out to be one of my own making; in my code I had set the Grid height according to the required number of rows and therefore the vertical scroll bar was not showing.
Thanks for your comment,

Roger

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial