[RESOLVED]event input

Using VS2010, asp.net4, c #, jquery

In my page. Aspx I have an input, how do I trigger an event when the server side usuáro enter the 4 carastere the input.

User enters 1234 on the input when he enter the characters 4, fires a server side event

solution

$(function () {
$("#TxtAnoLetivo").keyup(function () {
var tamanho = $("#TxtAnoLetivo").val().length;
if (tamanho == 4) {
alert(‘digitou 4′);
}
});
});

Leave a Reply