New to Telerik UI for ASP.NET MVC? Start a free 30-day trial

Defines the fluent interface for configuring the PanelBar events.

Definition

Constructors

C#
public PanelBarEventBuilder(IDictionary<string, object> events)
Parameters:eventsIDictionary<string, object>

Methods

Defines the handler of the Activate client-side event. Fires when the an item of the PanelBar is activated.

C#
public PanelBarEventBuilder Activate(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Example:
C#
@(Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events.Activate(@&lt;text&gt;
function(e) {
// Handle the Activate event inline.
}
&lt;/text&gt;)
)
)

Defines the handler of the Activate client-side event. Fires when the an item of the PanelBar is activated.

C#
public PanelBarEventBuilder Activate(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the event.

Returns:

PanelBarEventBuilder

Example:
C#
@( Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events
.Activate("onActivate")
)
)

Defines the handler of the Collapse client-side event. Fires when the an item of the PanelBar is collapsed.

C#
public PanelBarEventBuilder Collapse(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Example:
C#
@(Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events.Collapse(@&lt;text&gt;
function(e) {
// Handle the Collapse event inline.
}
&lt;/text&gt;)
)
)

Defines the handler of the Collapse client-side event. Fires when the an item of the PanelBar is collapsed.

C#
public PanelBarEventBuilder Collapse(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the event.

Returns:

PanelBarEventBuilder

Example:
C#
@( Html.Kendo().PanelBar()
.Name("PanelBar")
.Events(events =&gt; events.Collapse("collapse"))
)

Defines the handler of the ContentLoad client-side event. Fires when the content is fetched through an AJAX request.

C#
public PanelBarEventBuilder ContentLoad(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Example:
C#
@(Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events.ContentLoad(@&lt;text&gt;
function(e) {
// Handle the ContentLoad event inline.
}
&lt;/text&gt;)
)
)

Defines the handler of the ContentLoad client-side event. Fires when the content is fetched through an AJAX request.

C#
public PanelBarEventBuilder ContentLoad(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the event.

Returns:

PanelBarEventBuilder

Example:
C#
@( Html.Kendo().PanelBar()
.Name("PanelBar")
.Events(events =&gt; events.ContentLoad("contentLoad"))
)

Defines the handler of the DataBound client-side event. Fires after the DataSource Change event has been processed (adding/removing items).

C#
public PanelBarEventBuilder DataBound(Func<object, object> onDataBoundAction)
Parameters:onDataBoundActionFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Example:
C#
@(Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events.DataBound(@&lt;text&gt;
function(e) {
// Handle the DataBound event inline.
}
&lt;/text&gt;)
)
)

Defines the handler of the DataBound client-side event. Fires after the DataSource Change event has been processed (adding/removing items).

C#
public PanelBarEventBuilder DataBound(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the dataBound event.

Returns:

PanelBarEventBuilder

Example:
C#
@( Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events
.DataBound("onDataBound")
)
)

Defines the handler of the Error client-side event. Fires when the AJAX request results in an error. Note: This event will not fire when using jQuery v3.x.

C#
public PanelBarEventBuilder Error(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Example:
C#
@(Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events.Error(@&lt;text&gt;
function(e) {
// Handle the Error event inline.
}
&lt;/text&gt;)
)
)

Defines the handler of the Error client-side event. Fires when the AJAX request results in an error. Note: This event will not fire when using jQuery v3.x.

C#
public PanelBarEventBuilder Error(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the event.

Returns:

PanelBarEventBuilder

Example:
C#
@( Html.Kendo().PanelBar()
.Name("PanelBar")
.Events(events =&gt; events.Error("onError"))
)

Defines the handler of the Expand client-side event. Fires when an item of the PanelBar is expanded.

C#
public PanelBarEventBuilder Expand(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Example:
C#
@(Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events.Expand(@&lt;text&gt;
function(e) {
// Handle the Expand event inline.
}
&lt;/text&gt;)
)
)

Defines the handler of the Expand client-side event. Fires when an item of the PanelBar is expanded.

C#
public PanelBarEventBuilder Expand(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the event.

Returns:

PanelBarEventBuilder

Example:
C#
@( Html.Kendo().PanelBar()
.Name("PanelBar")
.Events(events =&gt; events.Expand("expand"))
)

Defines the inline handler of the KendoKeydown client-side event

C#
public virtual PanelBarEventBuilder KendoKeydown(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Defines the name of the JavaScript function that will handle the KendoKeydown client-side event.

C#
public virtual PanelBarEventBuilder KendoKeydown(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the event.

Returns:

PanelBarEventBuilder

Defines the handler of the Select client-side event. Fires when an item of the PanelBar is selected by the user.

C#
public PanelBarEventBuilder Select(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

PanelBarEventBuilder

Example:
C#
@(Html.Kendo().PanelBar()
.Name("panelbar")
.Events(events =&gt; events.Select(@&lt;text&gt;
function(e) {
// Handle the Select event inline.
}
&lt;/text&gt;)
)
)

Defines the handler of the Select client-side event. Fires when an item of the PanelBar is selected by the user.

C#
public PanelBarEventBuilder Select(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the event.

Returns:

PanelBarEventBuilder

Example:
C#
@( Html.Kendo().PanelBar()
.Name("PanelBar")
.Events(events =&gt; events.Select("select"))
)