Ver Mensaje Individual
  #3 (permalink)  
Antiguo 11/04/2007, 15:12
Kikofus
 
Fecha de Ingreso: abril-2007
Mensajes: 12
Antigüedad: 18 años
Puntos: 0
Re: ocultar o mostrar ergistros vacios de la base de datos

Gracias Myakire, aqui esta el codigo completo. Lo realice con Dreamweaver MX y conecta a una BD Acces

------------------------------

<%@LANGUAGE="VBSCRIPT"%>
<!--#include file="Connections/conex.asp" -->
<%
Dim rspromo
Dim rspromo_numRows

Set rspromo = Server.CreateObject("ADODB.Recordset")
rspromo.ActiveConnection = MM_conex_STRING
rspromo.Source = "SELECT * FROM promociones"
rspromo.CursorType = 0
rspromo.CursorLocation = 2
rspromo.LockType = 1
rspromo.Open()

rspromo_numRows = 0
%>
<%
Dim Repeat1__numRows
Dim Repeat1__index

Repeat1__numRows = -1
Repeat1__index = 0
rspromo_numRows = rspromo_numRows + Repeat1__numRows
%>
<html>
<head>
<title>Documento sin t&iacute;tulo</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>

<body>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="2">

<tr>
<td>
<table border="2" align="center" cellpadding="0" cellspacing="0" bordercolor="#00CCCC">
<tr>
<%
counter=0
Do While Not rspromo.EOF
%>
<td><a href="<%=(rspromo.Fields.Item("PROMOLINK").Value)% >"><img src="<%=(rspromo.Fields.Item("IMAGEN").Value)%>" alt="clic para mas informacion" hspace="5" vspace="5" border="0"></a></td>
<%
counter=counter+1
If counter Mod 4=0 Then Response.Write "</tr><tr>"
rspromo.MoveNext
Loop
%>
</tr>
</table>


</td>
</tr>
</table>

</body>
</html>
<%
rspromo.Close()
Set rspromo = Nothing
%>

-------------------------------------

Gracias