Easy Tutorial
❮ Mvc Security Prop Webcontrol Table Caption ❯

ASP.NET Button OnClientClick Property



Definition and Usage

The OnClientClick property is used to set a client-side script that runs when the Button control is clicked.

In addition to the predefined script, the script specified in this property runs through the button's "OnClick" event.

Syntax

Property Description
OnClientClick The client-side script to run when the button is clicked.

Example

Example

The following example runs two scripts when the Button control is clicked:


❮ Mvc Security Prop Webcontrol Table Caption ❯