Index: Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/AssemblyResultTotalView.cs =================================================================== diff -u -r5562ec9835fa2ad44ede7aa031e80c3e9a368445 -r40c8f42deadfa4e6c9df90b42ba496ceeb78135d --- Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/AssemblyResultTotalView.cs (.../AssemblyResultTotalView.cs) (revision 5562ec9835fa2ad44ede7aa031e80c3e9a368445) +++ Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/AssemblyResultTotalView.cs (.../AssemblyResultTotalView.cs) (revision 40c8f42deadfa4e6c9df90b42ba496ceeb78135d) @@ -163,18 +163,7 @@ private void HandleCellStyling(object sender, DataGridViewCellFormattingEventArgs e) { - var row = (FailureMechanismAssemblyResultRowBase) dataGridViewControl.GetRowFromIndex(e.RowIndex).DataBoundItem; - - if (row.ColumnStateDefinitions.ContainsKey(e.ColumnIndex)) - { - DataGridViewColumnStateDefinition columnStateDefinition = row.ColumnStateDefinitions[e.ColumnIndex]; - DataGridViewCell cell = dataGridViewControl.GetCell(e.RowIndex, e.ColumnIndex); - - cell.ReadOnly = columnStateDefinition.ReadOnly; - cell.ErrorText = columnStateDefinition.ErrorText; - cell.Style.BackColor = columnStateDefinition.Style.BackgroundColor; - cell.Style.ForeColor = columnStateDefinition.Style.TextColor; - } + dataGridViewControl.FormatCellWithColumnStateDefinition(e.RowIndex, e.ColumnIndex); } #region Failure mechanism assembly result rows