Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
608 | Jul 16,2002 02:20 PM UTC | Jul 16,2002 03:02 PM UTC | WinForms | 1 |
![]() |
Tags: GridControl |
//hook the handler in Form_Load... this.gridDataBoundGrid2.Model.QueryCellInfo += new GridQueryCellInfoEventHandler(HandleQueryCellInfo); //the handler private void HandleQueryCellInfo(object sender, GridQueryCellInfoEventArgs e) { if(e.ColIndex > 0 && e.RowIndex > 0) { if(e.RowIndex % 2 == 0) e.Style.BackColor = Color.Red; else e.Style.BackColor = Color.Blue; e.Handled = true; } }
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.