Come work for Umbraco - The Umbraco HQ are hiring Project managers, .NET developers and DevOps people!
Hi Guys, hoping you'll be able to help with an issue related to my custom field type I've created.
The field type Ive created is based on the CheckBox from the shared source code for contour. In essence it allows the user to create a checkbox that also contains a bulleted list (which is taken from the pre-values). This renders as a checkbox followed by a bulleted list of items, which is used to check that the person filling out the form has read the bulleted items and ticked the checkbox to confirm that they have read the list. This works fine until I try and set the field to mandatory; if I do this I get an error stating that Control 'e994b609_b996_4136_85b0_0b6cf95bdcce' referenced by the ControlToValidate property of 'mandatory' cannot be validated.
I suspect this is to do with that fact that my control in the class is a simple ASP CheckBox, rather than the ValidateableCheckBox used in the source code. If this is the case then what do I need to reference to use a ValidateableCheckBox rather than a standard CheckBox? Or is there a better way of doing this?
Ok, I thought I'd sorted this by using the Umbraco.Forms.Core.Controls.ValidateableCheckBox instead, however this does not work either. What am I missing?