% 'Variables de Entrada Area = Request.QueryString("Area") Linea = Request.QueryString("Linea") 'Abre la Base de Datos If IsObject(Session("DableContenido_conn")) Then Set conn = Session("DableContenido_conn") Else Set conn = Server.CreateObject("ADODB.Connection") conn.open "DableContenido","admin","687140" Set Session("DableContenido_conn") = conn End If 'Determina la sentencia Sql Where = "" If Area <> 0 then Where = " Where Area = " & Area End If If Linea <> 0 then If len(Where) > 0 then Where = Where & " or Linea = " & Linea else Where = "Where Linea = " & Linea end if End If 'Ejecuta la Sentencia Sql sql = "SELECT * FROM Contenido " & Where & " Order by Id" Set rs = Server.CreateObject("ADODB.Recordset") rs.Open sql, conn %>
<% 'Arma Todos los Registros Seleccionados Cuenta=0 On Error Resume Next rs.MoveFirst do while Not rs.eof Cuenta = Cuenta + 1 'Escribe el codigo HTML If len(trim(rs.Fields("Hipervinculo"))) > 0 then Response.Write(" |