How to Create a Custom Property
- Select Add new item in the solution explorer context menu.
- Select the Custom Property item.
- Enter a name for the Custom Property.
- A dialog will give you different options for how to create the property.
- Select Custom to write a property from scratch.
- Select Derived and specify a base class in the list of PropertyData types to be able to specify a suitable base class with a base implementation to extend.

- Check the "Create an associated Control" used for rendering the custom property” to alter the rendering of your custom property.
- Click OK.
Checklist
- The generated files should have the correct filename (for example: foo.cs, fooControl.cs, only if the option to create an associated property control was checked).
- The type defined in the code behind file should have a name based on the provided filename and be placed in the default namespace for the current project location.
- The type declared in the codebehind file should derive from EPiServer.Core.PropertyData if Custom was selected, otherwise the selected base class.
- If an associated property control was selected:
- The property class should have an override of the CreatePropertyControl that returns a new instance of the PropertyData control.
- The PropertyData control should have a property with the same name as the created PropertyData class.
- See examples below. Replace {property-name} with the create type name for the PropertyData class created.
public override EPiServer.Core.IPropertyControl CreatePropertyControl()
{
return new {property-name}Control();
}
public {property-name} {property-name}
{
get
{
return PropertyData as {property-name};
}
}