The AJAX Control toolkit for ASP.Net 2.0 provides a control called Accordion control extender that works like a collapsible panel control we discussed earlier. The AJAX Accordion control looks like a collection of Collapsible Panel controls in which one Panel opens and other previously expanded panel collapses. You can create as many panes in Accordion Control.
Accordion Control extender contains two types of templates, HeaderTemplate and ContentTemplate. Another part of Accordion Control is collection of Panes. Panes contain the collection AccordionPane having their own attributes and templates to hold the header and content. AccordionPane control extender works as child extender control for Accordion extender control.
Accordion extender control consists of in-built feature of animation that expands and collapses the Accordion Panes with fade effect or according to specific speed for frames per second.
AutoSize: It works according to the Height property of accordion control. AutoSzie property is of enumerator type with 3 values: None, Fill and Limit.
FadeTransitions: It allows the fade animation effect for expand and collapse behavior of Accordion Panes.
TransitionDuration: Time in milliseconds to complete the transition effect.
FramesPerSecond: number of frames per second to complete the transition effect. Higher the number for FramesPerSecond smoother will be the transition effect.
SelectedIndex: Index of the Accordion pane required as initially visible.
RequireOpenedPane: If true then it keeps the currently selected pane visible.
ContentCssClass: Name of the CSS class to apply the CSS styles on content template of Accordion Control.
HeaderCssClass: Name of the CSS class to apply the CSS styles on Header Template.
HeaderSelectedCssClass: Name of the CSS class to apply the CSS styles on the Header template of selected AccordianPane.
CSS Code:
<style type="text/css">
body { font-family: verdana; font-size: 11px; }
.content { width:300px; margin-bottom:2px; padding:2px; }
HTML code:
Be the first to rate this post
Tags: asp.net 2.0, ajax, ajax accordion control, asp.net ajax control toolkit, download ajax control toolkit, accordion extender, collapsiblepanel extender
8/23/2008 9:14:26 PM