DropDownList

Vote:
 

Hi,

I must be insane because I couldn’t get EPiServer 7.5 MVC to render a simple DropDownList in edit mode. A case of trying too hard and frustration led to this post. Why do they make it so difficult to do the simplest of things :)

I have googled and searched the forum but EPiServer has a specializedProperty and they don’t let you map a simple DropDownList to it?

Drop-down list

String (<= 255)

EPiServer.SpecializedProperties.PropertyDropDownList

EPiServer

 

public virtual DropDownList ActiveView { get; set; }


gives the error:

Why has this information not been added to this fine list here: http://world.episerver.com/Documentation/Items/Developers-Guide/EPiServer-CMS/75/Content/Properties/Property-types/ ?

Anyway, in case you are wondering. Since EPiServer.SpecializedProperties.PropertyDropDownList is a really a string, just do this: 

[UIHint("DropDownList")]

        public virtual string ActiveView { get; set; }

#86368
May 20, 2014 13:13
Vote:
 

For dropdownlists I often use a editordescriptor and pupulate that with my stuff. Then use the editordescriptor as [UIHint]. Something like Linus did in this blogpost: http://world.episerver.com/Blogs/Linus-Ekstrom/Dates/2012/9/EPiServer-7-Configuring-editors-for-your-properties/

#86370
May 20, 2014 13:19
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* 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.