Custom Dropdownlist property

Vote:
 
What's the best practice for doing this. Simply a dropdown that has custom items. I've tried this but can't get it to work. Get a javascript 'focus' error and data is not saved. public class BTAreaIdControl : PropertySelectControlBase { public override void CreateEditControls() { base.CreateEditControls(); EditControl.Items.Add(new ListItem(CurrentPage.PageName, "1")); EditControl.Items.Add(new ListItem("Annan sida", "2")); } public BTAreaId BTAreaId { get { return PropertyData as BTAreaId; } } } The BTAreaId class is as generated from VS.
#15996
Mar 25, 2008 19:07
Vote:
 
Take a look at the sample code provided in this forum thread: http://www.episerver.com/en/EPiServer_Knowledge_Center/Developer-Forum2/EPiServer-Developer-Forums-/EPiServer-CMS-version-5/13479/ /Mari
#16774
Mar 25, 2008 19:17
Vote:
 
Thank you, searched the forum for the wrong thing.
#16775
Mar 25, 2008 19:17
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.