AJAX - Deshabilitar timer con ajax

 
Vista:
sin imagen de perfil

Deshabilitar timer con ajax

Publicado por Matias (9 intervenciones) el 18/04/2013 07:01:44
Hola, quiero poder deshabilitar un timer desde una funcion Javascript, el timer lo tengo dentro de un formulario, y en cierta parte del programa llamo a la funcion "parar" pero no funciona.. aca les dejo el codigo. Gracias

1
2
3
4
5
6
7
8
9
10
11
<form id="form1" runat="server">
    <asp:Timer ID="Timer1" runat="server" Interval="6000">
</form>
 
<script language="javascript">
function parar(){
var timer = Sys.Application.findComponent('<%= Timer1.ClientID %>');
     timer._stoptimer();
     timer.set_enabled(false);
     }
</script>
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder