Ver Mensaje Individual
  #2 (permalink)  
Antiguo 11/11/2009, 13:00
Avatar de engonga
engonga
Usuario no validado
 
Fecha de Ingreso: marzo-2002
Ubicación: Buenos Aires
Mensajes: 1.300
Antigüedad: 23 años, 1 mes
Puntos: 8
Respuesta: 10 registros aleatorios

ya casi lo tengo

Código PHP:
<%  Dim connrst

Set rst
Server.CreateObject("ADODB.Recordset")
rst.ActiveConnection MM_hotel_STRING
rst
.Source "SELECT * FROM restaurantes where destacado ='1'"
rst.CursorType 2
rst
.CursorLocation 2
rst
.LockType 2
rst
.Open()



if 
not rst.EOF then
    rst
.moveFirst()
    for 
i=0 to 9
    a 
Int((rst.recordCount) * Rnd)
    
     
Te posiciones en el registro aleatorio
    rst
.move(a)%>
                <
li><a href="#primero"><%=rst("nombre")%> - <%=rst("localidad")%></a></li>
<% 
next 
end 
if
rst.close()
set rst nothing 
%> 

pero me sale el error

Código HTML:
ADODB.Field (0x80020009)
El valor de BOF o EOF es True, o el actual registro se eliminó; la operación solicitada requiere un registro actual.