Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.

ID: 21558, DrawGrid with ComboBox and CheckBox functionality

by Sergey Nosov Email: Anonymous

A VCL.NET descendant of the TCustomDrawGrid with Check Box columns, and Combo Box columns with drop down boxes that represented by TListBox components.
Download Details
FTP  download also available
CDN Login Required to Download. (You will be redirected to the login page if you click on the Download Link)
To download this, you must have registered:
A free membership

For Delphi, Version 8.0  to 8.0 553 downloads
Copyright: No significant restrictions

Size: 60,477 bytes
Updated on Thu, 18 Mar 2004 16:21:37 GMT
Originally uploaded on Thu, 18 Mar 2004 16:14:18 GMT
SHA1 Hash: 6D1B28E6497E90C9E2E91788992155E46BA8A1F0
MD5 Hash: 6F87C7C3BCA77792AE5E5D95316FFE81

    Explore the files in this upload

TExt2DrawGrid is a descendant of the TCustomDrawGrid class. It functions much like the standard DrawGrid, with added functionality of Check Box and Combo Box columns.

Combo box functionality is implemented through TListBox components that can be dropped alongside the grid on a form. The list then assigned at run time or at design time through the ComboBoxColumns property using a custom property editor. The grid will draw combo box buttons in the cells, and use the list boxes as drop down pick lists similar to the simple style ComboBox component.

Following Properties are implemented:

CheckBoxColumns: string
A by index coma delimited list of columns you would like to represent as Check Boxes. For example, if you want check boxes in the 2nd and 4th columns, set this property to: "2, 4" (without quotes).

ValueChecked, ValueUnchecked: variant
Values to represent the checked and unchecked state of the checkboxes. "True" and "False" by default.

ButtonMaxHeight: byte
Set to make the checkboxes and combo box buttons larger or smaller, when cell sizes allow.

ComboBoxColumns: TComboCollection
Maintains information on the columns you would like to represent as combo boxes. Each collection item implements following properties: ColumnIndex – index of the column in the grid, ListBox – the instance of TListBox used as drop down list for the specified column.

OnDropDown event is fired when drop down list box is shown.

Runtime references: Borland.Delphi, Borland.Vcl, System, System.Data, System.Drawing, System.XML, Borland.VclRtl.

Design time references: Borland.Delphi, Borland.Vcl, Borland.Vcl.Design.Standard, System, System.Data, System.Drawing, System.XML, Borland.VclRtl, Borland.Studio.Vcl.Design. In case both runtime and design time packages are implemented, the design time package requires the run time package.

Files included:

Ext2DrawGrid.pas – the main runtime unit that contains the component
ComboBoxColumnsEdtDlg.nfm – custom property editor form
ComboBoxColumnsEdtDlg.pas – the property editor form unit
ComboBoxColumnsEdt.pas – the property editor
Ext2DrawGrid.TExt2DrawGrid.bmp – component palette icon
Ext2DrawGridReg.pas – registration unit – a sample application
readme.txt – file that contains the information you are reading

To use the component, drop the TExt2DrawGrid on the form, then drop one or more TListBox components on the form on the same parent with the grid. In the object inspector click on the ellipses button for the ComboBoxColumns property to make list box to grid column associations. Set other properties as needed.

   Latest Comments  View All Add New

Move mouse over comment to see the full text

Could not retrieve comments. Please try again later.

Server Response from: ETNACDC03