elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.

 

 


Tema destacado: Usando Git para manipular el directorio de trabajo, el índice y commits (segunda parte)


  Mostrar Mensajes
Páginas: [1]
1  Programación / Programación Visual Basic / Capturar datos de checkbox en: 6 Septiembre 2013, 16:58 pm
Buenos dias, tengo un problema con la captura de datos de varios checkbox seleccionados.

Lo que quiero hacer es enviar todos los datos de checkbox seleccionados y capturarlos en un array en otra página, para luego realizar consultas sql .

Este es mi codigo en html.


Código
  1. <script language="javascript">
  2. function noborrar()
  3. {
  4. alert("Para modificar los datos favor de ingresar a sistema SUF.");
  5. }
  6.  
  7. <form method="POST" action="traspaso_suf.asp">
  8. <div align="center">
  9. <table border="0" width="85%" id="table3" cellspacing="0" cellpadding="0">
  10. <tr>
  11. <td align="center">
  12. <table border="1" width="100%" id="table4" style="border-left-width: 0px; border-right-width: 0px" bgcolor="#FFFFCC">
  13. <tr>
  14. <td colspan="5" bgcolor="#000080" style="border-style: solid; border-width: 1px">
  15. <b><font face="Arial" size="2" color="#FFFFFF">Proyectos en
  16. SUF (<%Response.Write r_usuario%>) </font></b></td>
  17. </tr>
  18. <tr>
  19. <td style="border-style: none; border-width: medium" width="8%">
  20. Selección</td>
  21. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="35%">
  22. Fecha</td>
  23. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="52%">
  24. Nombre del Proyecto</td>
  25. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="2%">
  26. &nbsp;</td>
  27. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="1%">&nbsp;</td>
  28. </tr>
  29. <%do while not udatos.eof%>
  30. <tr>
  31. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="8%">
  32. <input name="chk_turno" type="checkbox" value="<%=udatos("cod_proyecto")%>" onclick="document.getElementById('div_li_turno').s tyle. display = (this.checked) ? 'block' : 'none' " ></td>
  33. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="35%">
  34. <font size="3">
  35. <input name="T4" size="25" readonly value="<%=udatos("fecha")%>" style="font-family: Arial; "></font></td>
  36. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="52%">
  37. <font size="3">
  38. <input name="T3" size="72" readonly value="<%=udatos("nombre_proyecto")%>" style="font-family: Arial; "></font></td>
  39. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="2%">
  40. &nbsp;</td>
  41. <td style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium" width="1%">&nbsp;</td>
  42. </tr>
  43. <%udatos.movenext
  44.                loop
  45. %>
  46. </table>
  47. </td>
  48. </tr>
  49. </table>
  50. <input type="submit" value="Traspasar" name="B3"  style="color: #333333">
  51. </form>
  52.  
  53.  

El problema es como los capturo en el array.

Código
  1. <%
  2. dim vector()
  3. vector = Request.Form("chk_turno")
  4.  
  5. Set cn = Server.CreateObject("ADODB.Connection")
  6. cn.Open ("Provider=SQLOLEDB;Server=STGOSQL2K8;Database=IndapCred;Uid=R04; Pwd=R04;")
  7.  
  8. for i=0 to UBound(vector)
  9. Response.Write vector
  10.  
  11. next
  12.  
  13.  
  14. %>
  15.  
  16.  

Gracias por la ayuda.
2  Programación / Programación C/C++ / Funcion clonar en: 2 Mayo 2010, 19:21 pm
Hola tengo una duda sobre pilas dinamicas, debo crear un funcion clonar para una pila, pero no tengo idea como se puede realizar dicha funcion?, me orientan ? gracias.
3  Programación / Ejercicios / Re: Ayuda cn c++ en: 5 Abril 2010, 16:25 pm
Bien hagamos lo siguiente:

Matriz de 2x2:

[] [] [] []
[] [] [] []

El usuario ingresa el Nº10

[10] [1000] [12] [A]
[] [] [] []

Así debería quedar?


es algo parecido, solo que todas las conversiones del numero ingresado deben quedar ingersadas en una sola casilla. Ejemplo:

SE ingresa el Nº 10   :
[10 1000 12 A] [] [] []

4  Programación / Ejercicios / Re: Ayuda cn c++ en: 3 Abril 2010, 02:35 am
lo siento Np-アクス , sq.. levo recien avanzado el codigo para convertir el numero q se ingrese a binario, pero el modo de meter todo esto no lo c .
5  Programación / Ejercicios / Re: Ayuda cn c++ en: 2 Abril 2010, 16:32 pm
me refiero a que el programa te pedira que ingreses una serie de numeros, estos se guardaran en una matriz de n x m en formato decimal, binario, octal y hexadecimal.
6  Programación / Ejercicios / Re: Ejercicios resueltos C++ [programacion estructurada] en: 2 Abril 2010, 16:27 pm
Hola tengo una duda en este ejercicio
#include <stdio.h>
#include <conio.h>
int main ()
{
 int numero;
 printf("Inserte num. de dos digitos pares: ");
 scanf("%d",&numero);
 int aux=numero;
 if(numero<100 && numero>9)
 {
  int d1=numero%10;
  numero=numero/10;
  int d2=numero%10;
  if(d1%2==0 & d2%2==0)
   printf("El promedio d los digitos de %d es: %d",aux,(d1+d2)/2);
 }
 else
  printf("\aERROR: el numero no tiene dos digitos");
 getch();
}

Para que se usa el %10??, gracias.
7  Programación / Ejercicios / Ayuda cn c++ en: 2 Abril 2010, 01:42 am
Hola, soi nuevo, he visto que arta gente ayuda cn ejercicio un tanto complicado, les dejo el enunciado haber si me pueden ayudar. Se agradece.
Crear una matriz de n x m , en cada casilla se debe guardar el numero que se ingrese y ademas su formato decimal, binario, octal y hexadecimal, al final mostrar en pantalla todos los formatos del numero ingresado.
Páginas: [1]
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines