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

Defines the fluent API for configuring the Kendo UI Notification for ASP.NET MVC events.

Definition

Constructors

Initializes a new instance of the NotificationEventBuilder class.

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

The Notification event handlers.

Methods

Defines the handler of the Hide client-side event. Fires when a notification's hiding animation starts.

C#
public NotificationEventBuilder Hide(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag.

Returns:

NotificationEventBuilder

Returns the current instance of NotificationEventBuilder .

Example:
C#
@( Html.Kendo().Notification()
.Name("Notification")
.Events(events =&gt; events.Hide(
@&lt;text&gt;
function(e) {
//event handling code
}
&lt;/text&gt;
))
.Render();
)

Defines the handler of the Hide client-side event. Fires when a notification's hiding animation starts.

C#
public NotificationEventBuilder Hide(string handler)
Parameters:handlerstring

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

Returns:

NotificationEventBuilder

Returns the current instance of NotificationEventBuilder .

Example:
C#
@( Html.Kendo().Notification()
.Name("Notification")
.Events(events =&gt; events.Hide("onHide"))
)

Defines the handler of the Show client-side event. Fires when a notification's showing animation starts.

C#
public NotificationEventBuilder Show(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag.

Returns:

NotificationEventBuilder

Returns the current instance of NotificationEventBuilder .

Example:
C#
@( Html.Kendo().Notification()
.Name("Notification")
.Events(events =&gt; events.Show(
@&lt;text&gt;
function(e) {
//event handling code
}
&lt;/text&gt;
))
.Render();
)

Defines the handler of the Show client-side event. Fires when a notification's showing animation starts.

C#
public NotificationEventBuilder Show(string handler)
Parameters:handlerstring

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

Returns:

NotificationEventBuilder

Returns the current instance of NotificationEventBuilder .

Example:
C#
@( Html.Kendo().Notification()
.Name("Notification")
.Events(events =&gt; events.Show("onShow"))
)