Fixed more bugs with the parsing engine, a crash bug in the update inventory method, and a crash bug in the trimming operations. Deleting a row now marks all rows under it as dirty.
This commit is contained in:
@@ -683,12 +683,23 @@ namespace AdvertsingProfitControl
|
||||
//Reset the gAdSpecialIndex to -1.
|
||||
_adSpecialIndex = -1;
|
||||
e.Cancel = true; //Prevent the new row from being removed.
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
e.Cancel = true;
|
||||
}
|
||||
}
|
||||
//Mark all rows under the row that just got deleted as dirty.
|
||||
for (var index = currentRowIndex; currentRowIndex < dataGridView.Rows.Count; index++)
|
||||
{
|
||||
projectionsDataGridView.Rows[index].Cells[(int)SalesTableColumns.IsDirty].Value = true;
|
||||
projectionsDataGridView.Rows[index].HeaderCell.Style.BackColor = ApplicationColors.PendingEdit;
|
||||
inventoryDataGridView.Rows[index].Cells[(int)InventoryTableColumns.IsDirty].Value = true;
|
||||
inventoryDataGridView.Rows[index].HeaderCell.Style.BackColor = ApplicationColors.PendingEdit;
|
||||
actualSalesDataGridView.Rows[index].Cells[(int)SalesTableColumns.IsDirty].Value = true;
|
||||
actualSalesDataGridView.Rows[index].HeaderCell.Style.BackColor = ApplicationColors.PendingEdit;
|
||||
}
|
||||
}
|
||||
|
||||
private void ChangeAutoCompleteListOnKeyCombo(object sender, KeyEventArgs e)
|
||||
|
||||
Reference in New Issue
Block a user