+1-888-365-2779
Try Now
More in this section

Forums / Thunder / Custom field error - The control of type does not implement IField interface. All fields must implement IField interface.

Custom field error - The control of type does not implement IField interface. All fields must implement IField interface.

4 posts, 0 answered
  1. Nik
    Nik avatar
    10 posts
    Registered:
    06 May 2013
    13 Sep 2013
    Link to this post
    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
  2. Miroslava
    Miroslava avatar
    57 posts
    Registered:
    22 Feb 2016
    13 Sep 2013
    Link to this post
    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
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Nik
    Nik avatar
    10 posts
    Registered:
    06 May 2013
    13 Sep 2013
    Link to this post
    Ok, that worked. Why does putting in SitefinityWebApp.Fields.ListImage.ListImage work, but ~/Fields/ListImage/ListImage.ascx not?
  4. Miroslava
    Miroslava avatar
    57 posts
    Registered:
    22 Feb 2016
    16 Sep 2013
    Link to this post
    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

    Regards,
    Miroslava
    Telerik
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
4 posts, 0 answered