Ver Mensaje Individual
  #16 (permalink)  
Antiguo 20/04/2009, 12:15
Avatar de TonyChile
TonyChile
 
Fecha de Ingreso: marzo-2009
Ubicación: Maipú, Santiago
Mensajes: 422
Antigüedad: 16 años
Puntos: 7
Respuesta: LLamado a funcion desde un boton

Para poder llamar a la funcion lo estoy haciendo asi en el boton

Código asp:
Ver original
  1. <tr><td colspan="6" width="100%">&nbsp;</td></tr>
  2.     <tr>
  3.         <td colspan="6" align="center">
  4.             <input type="submit" name="BBbuscar" value="Buscar"  onClick="buscar()" onMouseover="showtip2(this,event,'Buscar la información Seleccionada');" onMouseout="hidetip2();" style="cursor:help">&nbsp;&nbsp;&nbsp;
  5.             <input type="button" name="BBlimpiar" value="Limpiar"  onClick ="BBmovil.value = '0'" onMouseover="showtip2(this,event,'Limpiar datos de Búsqueda');" onMouseout="hidetip2();" style="cursor:hand">
  6.         </td>
  7.     </tr>
  8.     <tr><td colspan="6">&nbsp;</td></tr>
  9. </table>
tambien lo pruebo con type button pero no pasa nada.

Y la funcion Buscar:

Código javascript:
Ver original
  1. <script language="javascript">
  2. function buscar()
  3. {        
  4.    
  5.       <%
  6.       movil = request.Form("BBmovil")
  7.      'if  BBmovil = MOVIL   then
  8.  
  9. sql2_2= "insert into tabla1 (rs2(0), rs2(1), rs2(2), rs2(3), rs2(4), rs2(5), rs2(6),
  10. rs2(7), rs2(8), rs2(9), rs2(10), rs2(11)) values " &  " ('" & NUM_CHIP & "',
  11. '" & MOVIL & "', '" & DATO1 & "', '" & DATO2 & "', '" & SERIE_CARPETA & "',
  12. '" & PIN & "', '" & PUK & "', '" & FECHA_ENTREGA_CHIP & "', '" & FECHA_RETIRO_CHIP & "', '" & ASIGNADO & "',
  13. '" & NO_ASIGNADO & "', '" & NOTAS & "') WHERE MOVIL = 'movil' "
  14.      
  15.       'sql2_2 ="select * from CHIP WHERE MOVIL = 'movil' "
  16.            
  17.        
  18.       'end if
  19.       %>
  20. }
  21. </SCRIPT>

Incluso probe asignandole un valor a WHERE MOVIL = '1' pero no pasa nada no se que ocurre, Que estoy haciendo mal
Si alguien sabe algo me puede ayudar. Gracias