protected virtual Control GetCellEditor(OLVListItem item, int subItemIndex)
{
OLVColumn column = this.GetColumn(subItemIndex);
Object value = column.GetValue(item.RowObject) ?? this.GetFirstNonNullValue(column);
// TODO: What do we do if value is still null here?
// Ask the registry for an instance of the appropriate editor.
Control editor = ObjectListView.EditorRegistry.GetEditor(item.RowObject, column, value);
// Use a default editor if the registry can't create one for us.
if (editor == null)
editor = this.MakeDefaultCellEditor(column);
return editor;
}