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.
Syncfusion Feedback

DataBoundGrid

Thread ID:

Created:

Updated:

Platform:

Replies:

14177 May 20,2004 01:11 AM UTC May 20,2004 01:50 PM UTC Windows Forms 3
loading
Tags: GridControl
Satish
Asked On May 20, 2004 01:11 AM UTC

Clay, Is there anyway we can make Column Heading as ''Fixed3D'' style and How can change the back color/font color of the selected cell. Thanks Satish

Administrator [Syncfusion]
Replied On May 20, 2004 05:56 AM UTC

I responded to the first question in your other forum thread. >>How can change the back color/font color of the selected cell Do you mean the current cell in the grid, and any cell that you have selected by dragging a cell range (or using teh keyboard to select cells). You can do both (just using different condition checks) by handling PrepareViewStyleInfo. Maybe with code similar to: GridCurrentCell cc = this.gridControl1.CurrentCell; if(cc.RowIndex == e.RowIndex && cc.ColIndex == e.ColIndex) { //color current cell e.Style.BackColor = Color.Black;//???? e.Style.TextColor = Color.White;//???? }

Satish
Replied On May 20, 2004 11:39 AM UTC

Clay, I have tried the code which you have mentioned here but not working. I need to change the backcolor/font color of ''current cell'' in the DataBoundgrid. If i moved to another cell, I should get back the old backcolor/fontcolor of the cell again. Thanks Satish >I responded to the first question in your other forum thread. > >>>How can change the back color/font color of the selected cell > >Do you mean the current cell in the grid, and any cell that you have selected by dragging a cell range (or using teh keyboard to select cells). > >You can do both (just using different condition checks) by handling PrepareViewStyleInfo. >Maybe with code similar to: > > >GridCurrentCell cc = this.gridControl1.CurrentCell; >if(cc.RowIndex == e.RowIndex && cc.ColIndex == e.ColIndex) >{ > //color current cell > e.Style.BackColor = Color.Black;//???? > e.Style.TextColor = Color.White;//???? >} >

Administrator [Syncfusion]
Replied On May 20, 2004 01:50 PM UTC

It seems to work OK for me in this minimal sample. What are you doing differently. WindowsApplication3_8994.zip

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.

Warning Icon 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.Close Icon

;