November Happy Hour will be moved to Thursday December 5th.
November Happy Hour will be moved to Thursday December 5th.
You need to add inputControl to the control collection.
Controls.Add(inputControl);Frederik
Thanks for your answer, but it doesnt make any difference. It still doesnt show upp in the Type dropdown.
Is there any other settings to make it appear? does it have to be in a specific namespace? or do I have to add it through the "Edit Custom Property Types" in admin?
Thanks in advance
/Fred
No, you don't have to add it to a specific namespace. If you check under Custom Property Types in admin mode does it appear there? If not, try inheriting from PropertyStringControl instead of PropertySelectControlBase.
Frederik
I still cant see my custom property under Custom Proeprty Types in Admin mode, my code looks lite this now:
[Serializable]
[PageDefinitionTypePlugIn]
public class MyDropDownCore : EPiServer.Core.PropertyString
{
public override IPropertyControl CreatePropertyControl()
{
return new MyDropDownCoreControl();
}
}
public class MyDropDownCoreControl : EPiServer.Web.PropertyControls.PropertyStringControl
{
protected DropDownList inputControl;
public override void CreateEditControls()
{
base.SetupEditControls();
inputControl.Items.Add("Red");
inputControl.Items.Add("Blue");
inputControl.Items.Add("Green");
inputControl.SelectedValue = this.PropertyData.Value as string;
Controls.Add(inputControl);
}
public MyDropDownCore MyDropDownCore
{
get
{
return PropertyData as MyDropDownCore;
}
}
}
Thanks for your help Frederik,
It was I that screwed up with something completely different. Now it works.
Hello
I have created a very simple custom property