Hi, I would like to know if there if it is possible to auto expand the parent row on a multi band grid every time we start editing a new parent row. Currently, when I start editing the new parent row the expand (+) icon becomes visible and you must click on it so that the child band gets a new row. I tried calling the ExpandAll method while in the InitializeRow method of the parent row but I realized that by doing this I loose focus from the cell I was editing on the parent row.
Hi,
Could you explain in more detail what you want? The Expansion Indicator doesn't suddenly show up when you start editing a row. By default, it displays all the time (assuming your data structure has a child band) and it will go away only if the user clicks on it and there are no child rows.
Using InitializeRow doesn't seem to fit in with what you are asking, because this event fires for every row, not just when you edit a row.
I would think you could just trap CellChanged or maybe AfterEnterEditMode and just set the Expanded property on the row. I don't think that should take the cell out of edit mode.
Thanks Mike. My problem was that for new rows the expansion indicator is not available yet. It only becomes available after you start editing the new row in the parent band.
I went with your suggestion of using the Expanded property in the AfterEnterEditMode event. That seems to work and the cell does not get out of edit mode. Thanks