I have written a custom field type with this definition (to be used in SP2010):
<FieldTypes>
<FieldType>
<Field Name="TypeName">MyField</Field>
<Field Name="ParentType">Number</Field>
<Field Name="TypeDisplayName">My Field</Field>
<Field Name="TypeShortDescription">My field description</Field>
<Field Name="AllowBaseTypeRendering">TRUE</Field>
<Field Name="UserCreatable">FALSE</Field>
<Field Name="FieldTypeClass">$SharePoint.Type.3e27f5e8-348d-40c6-afcc-87306b2bb3ac.AssemblyQualifiedName$</Field>
<Field Name="Sortable">TRUE</Field>
<Field Name="Filterable">TRUE</Field>
</FieldType>
</FieldTypes>
Basically, this custom field extend the native SPFieldNumber to provide a custom UI:
[Guid("3E27F5E8-348D-40C6-AFCC-87306B2BB3AC")]
public class MyField: SPFieldNumber
{
public MyField(SPFieldCollection fields, string fieldName)
: base(fields, fieldName)
{
}
public MyField(SPFieldCollection fields, string typeName, string displayName)
: base(fields, typeName, displayName)
{
}
public override Microsoft.SharePoint.WebControls.BaseFieldControl FieldRenderingControl
{
get
{
return new MyFieldControl
{
FieldName = this.InternalName,
};
}
}
}
The custom field works fine in the standard newform.aspx and editform.aspx. However, when I create a datasheet view, the field is read only:

What have I to do to make the field editable in the datasheet view?