Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
4695
ultragrid row backcolor not matching with the logic
posted

Dear all,

I have below code but don't know why the background color seems not matching with the logic. Is it because of inserting sequence??

private void ultraGrid1_InitializeRow(object sender, Infragistics.Win.UltraWinGrid.InitializeRowEventArgs e)        

 {            

try            

     {                

                    decimal newQty = Convert.ToDecimal(e.Row.Cells["itemNewQtyCol"].Value);

                   decimal cancelQty = Convert.ToDecimal(e.Row.Cells["itemCancelQtyCol"].Value);

                  if (newQty > 0 || cancelQty > 0)

                 {

                    e.Row.Appearance.BackColor = COLOR_NEW;

                 }

                else

                    e.Row.Appearance.BackColor = COLOR_NOT_DONE;

                }

             catch (Exception ex)  

           { }        

 }