We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Grid Control

Thread ID:

Created:

Updated:

Platform:

Replies:

434 Jun 25,2002 08:00 PM Jun 26,2002 08:34 PM Windows Forms 4
loading
Tags: GridControl
Sam Horton
Asked On June 25, 2002 08:00 PM

For a Grid, how do I programmatically control the Column headers (replace the A-Zs)?

Clay Burch [Syncfusion]
Replied On June 26, 2002 06:12 AM

> For a Grid, how do I programmatically control the > Column headers (replace the A-Zs)? > > In Essential Grid, you can view the column headers as row zero. So, if you want col header 1 to have the header "Price", you can set the Text property for the style of cell 0,1 to "Price". gridControl1[0,1].Text = "price"; or in VB, gridControl(0,1).Text = "price"

Sam Horton
Replied On June 26, 2002 07:55 AM

Thanks - Great tip! I also have a GridDataBoundGrid, but the object is quite different. For that type of control, how does one programmatically: (a) Set column text (b) Make the grid read-only (c) Freeze a column or row (d) Apply styles to cells, columns and rows If these are operations only possible in the Grid let me know and I'll use it instead.

Clay Burch [Syncfusion]
Replied On June 26, 2002 01:11 PM

The GridDataBoundGrid is more of a column oriented grid. To set column properties, you can use the designer and work with the GridBoundColumns property. Using the editor, add a GridBoundColumn for each of your columns. Make sure you set the MappingName for each column so the column can be matched to the datasource. You can also set style properties for each column here as well. So, GridDataBoundGrid is basically a column centric grid, but you can do special things with events to catch specific cell appearance if needed.

Sam Horton
Replied On June 26, 2002 08:34 PM

Thank you, Clay!

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;