Version

Templating

WebDropDown™ supports templating, which allows you to define an item template that can be used to customize the appearance of value list items. The Item template can be defined using the ItemTemplate property. Auto complete and filtering can be performed on the WebDropDown even when templating is applied. Using the templating feature, you can also define a custom control to be in the drop-down container.

Note
Note:

There can be only one custom control in the items list. For example, you can have either the WebCalendar™ control or the WebGrid™ control but not both in the drop-down list.

In order to set the value display of the WebDropDown control, you need to handle the client-side events that the underlying control offers.If multiple columns are in the template instead of a simple list, you can set the WebDropDown control’s TextField property to the column name you want to show in the value display.

WebDropDown not only allows you to set the item template for the contents, but also allows you to set the templates for the header and footer contents of the drop-down container using the HeaderTemplate and FooterTemplate properties. You can also apply a template to the loading message when the load-on-demand feature is enabled using the LoadingItemsMessageTemplate property.

Click the links below to find more information on how to use templating in WebDropDown: