Greetings,
I am trying to create a custom editor for one of my properties. The code I use is this:
[Android.Runtime.Register("my/name/space/ReaderEditor")]
public class ReaderEditor : Com.Telerik.Widget.Dataform.Visualization.Core.EntityPropertyEditor
{
public ReaderEditor(RadDataForm form, IEntityProperty property) : base(form,
form.EditorsMainLayout,
form.EditorsHeaderLayout,
Resource.Id.data_form_text_viewer_header1,
Resource.Layout.DataFormTextViewerLayout,
Resource.Id.data_form_text_viewer,
form.EditorsValidationLayout,
property)
{
}
public ReaderEditor(RadDataForm dataForm, int layoutId, int headerLayoutId,
int headerViewId, int editorLayoutId, int editorViewId,
int validationLayoutId, IEntityProperty property) :
base(dataForm, layoutId, headerLayoutId, headerViewId, editorLayoutId,
editorViewId, validationLayoutId, property)
{
}
public override Java.Lang.Object Value()
{
return ((EditText)EditorView).Text;
}
protected override void ApplyEntityValueToEditor(Java.Lang.Object entityValue)
{
((EditText)EditorView).Text = entityValue.ToString();
}
}
It's pretty basic actually, I just wanted to create a simple one in order to build on that afterwards. However when I run it I get the following exception:
Java.Lang.Error: The data form editor for property MYPROPERTY must have a constructor that accepts a Context and an EntityProperty.
How can I implement this editor?
Thank you for your time,
Vaggelis