Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
7101 | Sep 11,2003 11:53 PM UTC | Mar 12,2004 07:45 PM UTC | WinForms | 5 |
![]() |
Tags: GridControl |
private void grid_CurrentCellMoved(object sender, GridCurrentCellMovedEventArgs e) { GridCurrentCell cc = this.gridControl2.CurrentCell; this.gridAwareTextBox2.ReadOnly = this.gridControl2[cc.RowIndex, cc.ColIndex].ReadOnly; if(this.gridAwareTextBox2.ReadOnly) this.gridAwareTextBox2.BackColor = Color.White; }
>private void grid_CurrentCellMoved(object sender, GridCurrentCellMovedEventArgs e) >{ > GridCurrentCell cc = this.gridControl2.CurrentCell; > this.gridAwareTextBox2.ReadOnly = this.gridControl2[cc.RowIndex, cc.ColIndex].ReadOnly; > if(this.gridAwareTextBox2.ReadOnly) > this.gridAwareTextBox2.BackColor = Color.White; >} >>
private void gridControl1_CurrentCellActivating(object sender, GridCurrentCellActivatingEventArgs e)
{
if(e.RowIndex == 0)
e.Cancel = true;
}
This does not work for interior cells unless you want not to ss the currentcell frame when you click one. (This normally does not cause a problem with header, but does with regular cells.
>private void gridControl1_CurrentCellActivating(object sender, GridCurrentCellActivatingEventArgs e)
>{
> if(e.RowIndex == 0)
> e.Cancel = true;
>}
>
>
>This does not work for interior cells unless you want not to ss the currentcell frame when you click one. (This normally does not cause a problem with header, but does with regular cells. 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.
This page will automatically be redirected to the sign-in page in 10 seconds.