Custom field error - The control of type does not implement IField interface. All fields must implement IField interface.
I'm having issues adding a custom field to a list item. I added the default Sitefinity Field Control via Thunder in VS2012. Without making any changes, I compiled and then added the field. It adds, but I get the error as soon as I click Save on the main screen. Why would even the default template not work?!
Using Sitefinity 6.1.4600.0
Hello Nikolei,
Thank you for contacting Telerik support.
If you have TestFieldControl placed in a MyWidgets folder inside Sitefinity WebApp, then you have to enter "SitefinityWebApp.MyWidgets.TestFieldControl" for "Type or Virtual path of the custom widget" in Sitefinity backend when you add your custom field. Please, find screenshots I attached.
Setting incorrect type of the field control might be causing the error you are experiencing.
Regards,
Miroslava
Telerik
Ok, that worked. Why does putting in SitefinityWebApp.Fields.ListImage.ListImage work, but ~/Fields/ListImage/ListImage.ascx not?
Hello Nikolei,
Actually the label under textbox for entering your field control is confusing for those who create and use field controls for the first time. You have to enter the full type to the field. That is why we generate a clarifying comment in the field control code:
/// <summary>
/// A simple field control used to save a string value.
/// Use the path to this class when you add the field control
/// SitefinityWebApp.<your field control>
/// </summary>
Here is a video showing step by step how to create and use a field control:
https://www.youtube.com/watch?v=iDHY-UBhBrw