
03/11/2004, 08:48
|
| | Fecha de Ingreso: marzo-2004
Mensajes: 32
Antigüedad: 21 años, 1 mes Puntos: 0 | |
Problema con conexión he creado con dsn una conexión a una base de datos de acces muy sencilla, y no me funciona, lo meto en wwwroot, y lo ejecuto como localhost y nada de los registros
os dejo el código, es sencillo pero estoy bloqueado, a ver si alguien me puede ayudar
<html>
<head>
<!-- TemplateBeginEditable name="doctitle" -->
<title>Prueba de conexión</title>
<!-- TemplateEndEditable -->
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<!-- TemplateBeginEditable name="head" -->
<!-- TemplateEndEditable -->
</head>
<body>
<% Set conexion=Server.CreateObject("ADODB.Connection")
conexion.Open "DSN=hector1"
Set st= conexion.Execute("SELECT * FROM HEC1") %>
<table border="1" align="center">
<tr>
<th>NOMBRE</th>
<TH>APELLIDOS</TH>
<TH>EDAD</TH>
</tr>
<%while not st.EOF%>
<TR>
<TD><%st("NOMBRE")%></TD>
<TD><%st("APELLIDOS")%></TD>
<TD><%st("EDAD")%></TD>
</TR>
<% st.Movenext
Wend
st.Close
Set st=Nothing
conexion.Close
Set conexion=Nothing%>
</table>
</body>
</html>
gracias, un saludo |