FrmDatos y FrmExec: Corregir carga de imágenes

This commit is contained in:
2013-11-26 23:22:35 +01:00
parent 9940c5dcb9
commit 0ab98aef0e
3 changed files with 13 additions and 1 deletions

View File

@@ -144,6 +144,17 @@ namespace ServerExplorer.UI
dgvDatos.DataSource = ddt;
}
private void dgvDatos_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
{
if (e.DesiredType == typeof(Image))
{
if (e.Value is DBNull || (e.Value is byte[] && ((byte[])e.Value).Length <= 0))
{
e.Value = new Bitmap(1, 1);
}
}
}
}