|    
			
				07/09/2002, 11:18
			
			
			  | 
  |   |  |  |  Fecha de Ingreso: febrero-2002 
						Mensajes: 115
					 Antigüedad: 23 años, 8 meses Puntos: 1 |  | 
  |  Re: Cómo accedo MySQL con ASP  ¿Puedo?  
  Te paso algunos ejemplos ,, que tambien sirven con el chilisoft...
 Saludos
 
 PARA CONECTAR A UNA DB .DBF
 ---------------------------------------------------------------
 <%
 
 set oconn = server.createobject("ADODB.Connection")
 set Tabla = server.createobject("ADODB.Recordset")
 
 directorio = server.mappath(".")
 archivo_dbf = "tu_archivo.dbf"
 
 oConn.Open "Driver={Microsoft dBASE Driver (*.dbf)};" & "DriverID=277;" & "Dbq=" & directorio & ";"
 Tabla.Open "Select * From " & archivo_dbf & ".dbf", oConn,1 ,2
 
 %>
 
 <table width="100%" cellspacing="1" cellpadding="2">
 <tr>
 <%
 for i=0 to Tabla.fields.count-1
 %>
 <td align="center" style="border: 1 solid #000000" bgcolor="#336699"><font face="Arial" size="1" color="#FFFFFF"><b><%=Tabla(  i).name%></font></td>
 <% Next %>
 
 </tr>
 
 <%
 If not Tabla.eof and not Tabla.bof then
 rows = 0
 Do while not Tabla.eof
 rows = rows + 1
 %>
 <tr>
 <%
 For i=0 to Tabla.fields.count-1
 %>
 <td align="center" style="border: 1 solid #000000" bgcolor="#FFFFFF"><font face="Arial" size="1" color="#000000"><%=Tabla(i)%>&l  t;/font></td>
 <%
 Next
 %>
 </tr>
 <%
 Tabla.movenext
 Loop
 Response.Write "Existen " & rows & " registros en " & archivo_dbf
 Else
 Response.write "No se encontraron registros "
 End if
 %>
 </table>
 
 
 PARA CONECTAR CON ASP A UNA DB MYSQL
 --------------------------------------------------------------------
 
 <%
 Dim strParametros,cnnForos
 strParametros = "Driver={MySQL};SERVER=localhost;DATABASE=nom  breBaseDatos;UID=nombreUsuario;PASSWORD=password&q  uot;
 Set cnnForos = Server.CreateObject("ADODB.Connection")
 cnnForos.Open strParametros
 %>
 
 
     |