Ejemplo n.º 1
0
 private void gvProduct_CustomizeCell(object sender, Resco.Controls.SmartGrid.CustomizeCellEventArgs e)
 {
     if (!e.Cell.Header)
     {
         if (e.Cell.ColumnIndex == 0)
         {
             if ((e.Cell.Data as string) == "ไม่พบ")
             {
                 e.Cell.Style = this.gvProduct.Styles["styleRed"];
             }
             else
             {
                 e.Cell.Style = this.gvProduct.Styles["styleBlack"];
             }
         }
     }
 }
Ejemplo n.º 2
0
 private void smartGridDesc_CustomizeCell(object sender, Resco.Controls.SmartGrid.CustomizeCellEventArgs e)
 {
     try
     {
         var cell = e.Cell;
         if (cell.ColumnIndex == 3)
         {
             if (cell.Text != "")
             {
                 cell.Style = this.smartGridDesc.Styles["Number"];
             }
         }
     }
     catch (Exception ex)
     {
         GlobalMessageBox.ShowError(ex);
     }
 }