It depends on how much white space you find ugly, but one thing you can do to minimize it is getting into the carriage by returning immediately after being equal. Then you will get something like this. `
{ var raw_custs = (from customer in GetActive() where customer.Name.Contains(name) select customer).Take(numberToGet).ToList();
I usually press CTRl-E CTRL-D immediately after making such a change so that the document is automatically formatted (Edit-> Advanced-> Format Document)
(Just saw your corrected post - when I put this in VS and typed return after + =
dataView.CellFormatting += (s, e) => { if ((e.ColumnIndex == 1) && ((dataView.SelectedCells.Count == 1))) { var scope = Scope.Instance; var row = dataView.Rows[e.RowIndex]; var variable = row.DataBoundItem as Variable; if (scope.Variables.Contains(variable)) { dataView[e.ColumnIndex, e.RowIndex].Style.BackColor = scope.GetGraph(variable).Color; } else { dataView[e.ColumnIndex, e.RowIndex].Style.BackColor = Color.White; } }
source share