Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
330
Manual Adjustment of LabelWidth causes Active Cell to become no longer in edit mode.
posted

Hello,

I am having an issue where I have to adjust the cell width to accomodate a dynamic control at runtime. The control may be composed of numerous text boxes and we won't know the size until after the Loaded event gets called on it.

My current workaround is to wire up to the Loaded event of the control in the EditModeStarted event on the grid. Once the control gets loaded i do the following:

_currentGrid.ActiveCell.Field.Settings.LabelWidth = newWidth;

Unfortunately, it seems that LabelWdith changes causes the active cell to no longer be in edit mode and so our focus never goes into the control. Is there any way to address this issue?

Also, this only seems to occure when tabbing into the field. Directly clicking does not cause the cell to exit edit mode.

Thanks.