UPDATE::
RESOLVED:
I was looking in the wrong place (design view) i used in code "GridView1.MasterGridViewTemplate.AutoGenerateColumns = False" , that resolved this issue, many thanks!!!
Roberto.
private void radGridView1_CellEndEdit(object sender, GridViewCellEventArgs e)
{
int rowIndex = e.RowIndex; //is -1, since it's a new row
int columnIndex = e.ColumnIndex; //is 0, since it's the 1st column that's being editited by the user.
GridViewRowInfo row = this.radGridView1.MasterGridViewInfo.CurrentRow; //The only way to get the row (since rowindex => -1)
string cellText = row.Cells[0].CellElement.Text; //is 'ABC', as entered by the user
string cellValue = (string)row.Cells[0].Value; /is <Null> ??????
row.Cells[0].Text = string.Join(",", new string[] { cellText, cellText }); //Concatenats into 'ABC,ABC' and overwites the cells text with that.
}
Now when you look at the cell on screen, you'll see that it still presenting it as 'ABC'.
Remarks.
1) Setting the Cell value does not help in any way.
2) The code above does work if the row is not a new row.
3) If the grid is under VirtualMode = true, then NO text can be read from that cell in the snippet.
I would like to know what is there to do to have the value/text being overwitten on CellEndEdit' in case of a NEW row. It's a key requirement for the application I'm working on.
Kind regards,
Jack