Ver Mensaje Individual
  #2 (permalink)  
Antiguo 29/04/2002, 09:30
Avatar de bakanzipp
bakanzipp
 
Fecha de Ingreso: noviembre-2001
Ubicación: santiago de shilli
Mensajes: 2.554
Antigüedad: 23 años, 5 meses
Puntos: 0
Re: Resultados Segun Busqueda

bueno...

primero debes tener dos input para ingresar los apellidos..

<form method=post action=pagina.asp>
<table>
<tr>
<td>Apellido Paterno</td>
<td><input type=text name=apellidop></td>
</tr>
<tr>
<td>Apellido Materno<td>
<td><input type=text name=apellidom></td>
</tr>
<tr>
<td></td>
<td><input type=submit name=buscar value=Buscar></td>
</tr>
</table>
<%if request("buscar")="Buscar" then
Dim oConn, rs, SQL
set oConn = Server.CreateObject("ADODB.Connection")
oConn.Open "Driver={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("tu_bd.mdb")
SQL="SELECT notas FROM alumno where apellidop='"& request("Apellidop") &"' and apellidom='"& request("Apellidom") &"'"
set rs = oConn.Execute(SQL)
if rs.EOF then
Response.Write("No hay ningún registro")
else%>
'si es mas de 1 reg
<table>
<%while not rs.eof%>
<tr>
<td><%=rs("notas")%></td>
<%rs.movenext%>
</tr>
<%wend
end if
rs.Close
set rs = nothing
oConn.Close
set oConn = nothing
%>
</table>
</form>


uffff...me canse





</form>