Foros del Web » Programando para Internet » ASP Clásico »

Quien puede y me ayuda en Error Microsoft VBScript runtime error '800a01a8'

Estas en el tema de Quien puede y me ayuda en Error Microsoft VBScript runtime error '800a01a8' en el foro de ASP Clásico en Foros del Web. hola saludos, tengo poco tiempo en esta pagina, y la neta he visto que esta muy buena, se han despejado muchas de mis dudas que ...
  #1 (permalink)  
Antiguo 05/12/2008, 14:20
 
Fecha de Ingreso: diciembre-2008
Mensajes: 17
Antigüedad: 16 años, 4 meses
Puntos: 0
Quien puede y me ayuda en Error Microsoft VBScript runtime error '800a01a8'

hola saludos, tengo poco tiempo en esta pagina, y la neta he visto que esta muy buena, se han despejado muchas de mis dudas que he tenido, pero hace poco me dieron en mis manos un proyecto que se encuentra en asp, y soy nuevo en esto, espero su ayuda. El sistema ya esta realizado y ya he resuelto muchos errores que tenia pero tienen muchos mas. este es uno de ellos, espero me ayuden.

Microsoft VBScript runtime error '800a01a8'
Object required: '' /sigisi/expedientes/index.asp, line 256

en la linea 256 se encuentra esto
Recordset1.Close()

El código completo es:

<%if(session("expedientes"))<>1 then%>
<HTML>
<head>
<title>Portal SIPRA-FH</title>
<BASE id="bseHref" href="http://ctizmccsipra01/" />
<LINK href="css/Default.css" rel=stylesheet>
<LINK href="css/blue.css" rel=stylesheet>
<SCRIPT LANGUAGE="JavaScript" SRC="js/fecha.js"></SCRIPT>
<SCRIPT LANGUAGE="JavaScript" SRC="js/ValidacionPrueba.js"></SCRIPT>
</head>
<HTML>
<HEAD>
<TITLE>Inicio</TITLE>
</HEAD>
<BODY>
<H3>ACCESO DENEGADO.</h3>
<br><br>
<H5><center>Usted no cuenta con derechos para activar esta opcion<br> o su sesion a caducado (Reinicie su sesion en el sistema).<br><br><br>Cualquier duda favor de comunicarse con el administrador del sistema.<br>
GRACIAS.</center></H5>
</BODY>
</HTML>
<%else%>

'<!--#include file="Connections/SEC.asp" -->
'<%
'Dim Recordset1__MMColParam
'Recordset1__MMColParam = "1"
'If (Request.QueryString("ID") <> "") Then
'Recordset1__MMColParam = Request.QueryString("ID")
'End If
'%>
'<%
'Dim Recordset1
'Dim Recordset1_numRows
'Set Recordset1 = Server.CreateObject("ADODB.Recordset")
'Recordset1.ActiveConnection = MM_SEC_STRING
'Recordset1.Source = "SELECT * FROM dbo.vwSIPRAResultadosXEmpleados WHERE Ficha = '" + Replace(Recordset1__MMColParam, "'", "''") + "' ORDER BY Fecha ASC"
'Recordset1.CursorType = 0
'Recordset1.CursorLocation = 2
'Recordset1.LockType = 1
'Recordset1.Open()
'Recordset1_numRows = 0
'%>
<%
Dim Repeat1__numRows
Dim Repeat1__index
Repeat1__numRows = -1
Repeat1__index = 0
Recordset1_numRows = Recordset1_numRows + Repeat1__numRows
%>
<!--#INCLUDE FILE="../../inc/base.asp"-->
<body>
<table class="xdLayout" style="WIDTH: 95%; BORDER-TOP-STYLE: none; BORDER-RIGHT-STYLE: none; BORDER-LEFT-STYLE: none; BORDER-COLLAPSE: collapse; WORD-WRAP: break-word; BORDER-BOTTOM-STYLE: none" cellPadding="5" border="0">
<tbody vAlign="top">
<tr>
<td style="PADDING-RIGHT: 5px; PADDING-LEFT: 5px; PADDING-BOTTOM: 5px; VERTICAL-ALIGN: bottom; PADDING-TOP: 5px; BORDER-BOTTOM: 5pt solid" class="primaryVeryDark">
<h6 style="FONT-WEIGHT: normal">
<font face="Verdana" size="4">Capacitación</font>
</h6>
</td>
</tr>
<tr>
<td style="BORDER-TOP: 5pt solid; VERTICAL-ALIGN: bottom" class="primarylight">
<%
if request.querystring("ID") = "" then %>
<form action="/SIGISI/expedientes/index.asp" method="get" name="FormaFicha" target="contents">
Por favor inserte el n&uacute;mero de ficha a buscar :<br />
<input type="text" name="ID" size="12"><input type="submit" value="Buscar">
</form>
</td>
</tr>
</tbody>
</table>
<p>
<% else
set RS=Server.CreateObject("ADODB.Recordset")
RS.Open "SELECT Ficha,nombre,appaterno,apmaterno FROM expLaboral where Ficha=" & Request.querystring("ID"),conn,3,3
if not RS.EOF THEN%>
Ficha encontrada: <br>
<b><%=RS("Ficha")%> - <%=RS("nombre")%>&nbsp;<%=RS("appaterno")%>&nbsp;< %=RS("apmaterno")%></b>
</p>
<a href="#" target="contents" onClick="javascript:location.reload()"><span style="font-size: 10px">Recargar Información</span></a>
</td>
</tr>
</tbody>
</table><br />
<% set RS2=Server.CreateObject("ADODB.Recordset")
RS2.Open "SELECT clave, fecha, observaciones, aprobado, asistio, clave_id from exp_cases WHERE ficha='" & request.querystring("ID") & "' ORDER BY id ASC",conn,3,3
%>
<table width="95%" border="1" cellspacing="2" cellpadding="2">
<tr><td colspan="8"><div align="center" style="font-size: 14px"><strong><em>Cursos CASES</em></strong></div></td>
</tr>
<tr>
<td><span style="font-size: 12px; font-weight: bold">Clave del Curso</span></td>
<td><span style="font-size: 12px; font-weight: bold">Nombre</span></td>
<td><span style="font-size: 12px; font-weight: bold">Qui&eacute;n imparti&oacute; </span></td>
<td><span style="font-size: 12px; font-weight: bold">Fecha de Capacitaci&oacute;n </span></td>
<td><span style="font-size: 12px; font-weight: bold">Fecha de Expiraci&oacute;n </span></td>
<td><span style="font-size: 12px; font-weight: bold">Aprobó</span></td>
<td><span style="font-size: 12px; font-weight: bold">Asistió</span></td>
<td><span style="font-size: 12px; font-weight: bold">Observaciones</span></td>
</tr>
<%DO WHILE not RS2.eof%>
<tr>
<td><span style="font-size: 10px"><%=RS2("clave")%></span></td>
<% set RS3=Server.CreateObject("ADODB.Recordset")
RS3.Open "SELECT nombre from cases_claves WHERE clave=" & RS2("clave") & " ORDER BY id ASC",conn,3,3
set RS25=Server.CreateObject("ADODB.Recordset")
sql = "SELECT profesor from cases WHERE clave_id='" & RS2("clave_id") & "'"
'response.write sql
RS25.Open sql,conn,3,3
%>
<td><span style="font-size: 10px"><%=RS3("nombre")%></span></td>
<td><span style="font-size: 10px"><%=RS25("profesor")%></span></td>
<td><span style="font-size: 10px"><%=RS2("fecha")%></span></td>
<td><span style="font-size: 10px"><% expir = DateAdd("yyyy", 2, RS2("fecha"))
expir2 = DateDiff("m",Date,expir)
'response.write expir2
if expir2 < 2 then %>
<span style="color: #FF0000">
<% end if %>
<%=DateAdd("yyyy", 2, RS2("fecha")) %></span></span></td>
<td><span style="font-size: 10px"><%=RS2("aprobado")%></span></td>
<td><span style="font-size: 10px"><%=RS2("asistio")%></span></td>
<td><span style="font-size: 10px"><%=RS2("observaciones")%></span></td>
</tr>
<%RS2.MOVENEXT
LOOP%>
</table>
<% set RS2=Server.CreateObject("ADODB.Recordset")
RS2.Open "SELECT id, curso, fecha, profesor, observaciones from exp_seguridad WHERE ficha=" & request.querystring("ID") & " ORDER BY id ASC",conn,3,3
%>
<br />
<table width="95%" border="1" cellspacing="2" cellpadding="2">
<tr><td colspan="5"><div align="center" style="font-size: 14px"><strong><em>Cursos de Seguridad </em></strong></div></td>
</tr>
<tr>
<td><span style="font-size: 12px; font-weight: bold">Nombre del Curso</span></td>
<td><span style="font-size: 12px; font-weight: bold">Fecha de Capacitaci&oacute;n </span></td>
<td><span style="font-size: 12px; font-weight: bold">Qui&eacute;n imparti&oacute; </span></td>
<td><span style="font-size: 12px; font-weight: bold">Observaciones</span></td>
<td><span style="font-size: 12px; font-weight: bold">
<% if lcase(session("tipo")) = "admin" then%>
<%="<strong>Edición</strong>"%>
<%end if %>
</span></td>
</tr>
<%DO WHILE not RS2.eof%>
<tr>
<td><span style="font-size: 10px"><%=RS2("curso")%></span></td>
<td><span style="font-size: 10px"><%=RS2("fecha")%></span></td>
<td><span style="font-size: 10px"><%=RS2("profesor")%></span></td>
<td><span style="font-size: 10px"><%=RS2("observaciones")%></span></td>
<td><span style="font-size: 10px"><% if lcase(session("tipo")) = "admin" then%>
<%="<a href=/SIGISI/expedientes/seg_edit.asp?id=" & RS2("id") & " target=contents>(Editar)</a> <a href=/SIGISI/expedientes/seg_del.asp?id=" & RS2("id") & " target=contents>(Borrar)</a>" %>
<%else%>
<%="" %>
<% end if %></span></td>
</tr>
<%RS2.MOVENEXT
LOOP%>
<tr><td colspan="5"><br /><div align="right"><span style="font-size: 10px"><%="<a href=/SIGISI/expedientes/seg_add.asp?ficha=" & request.querystring("ID") & ">Agregar Curso</a>" %></span></div></td></tr>
</table>
<br />
<% set RS2=Server.CreateObject("ADODB.Recordset")
RS2.Open "SELECT id, curso, fecha, profesor, observaciones from exp_categoria WHERE ficha=" & request.querystring("ID") & " ORDER BY id ASC",conn,3,3
%>
<table width="95%" border="1" cellspacing="2" cellpadding="2">
<tr><td colspan="5"><div align="center" style="font-size: 14px"><strong><em>Cursos requeridos por categoría</em></strong></div></td>
</tr>
<tr>
<td><span style="font-size: 12px"><strong>Nombre</strong></span></td>
<td><span style="font-size: 12px"><strong>Fecha de Capacitaci&oacute;n </strong></span></td>
<td><span style="font-size: 12px"><strong>Qui&eacute;n imparti&oacute; </strong></span></td>
<td><span style="font-size: 12px"><strong>Observaciones</strong></span></td>
<td><span style="font-size: 12px">
<% if lcase(session("tipo")) = "admin" then%>
<%="<strong>Edición</strong>"%>
<%end if %>
</span></td>
</tr>




puse primera parte del codigo pk esta muy largo, pero antes comentarie una parte, que se encuentra a partir de la linea 27
  #2 (permalink)  
Antiguo 05/12/2008, 14:20
 
Fecha de Ingreso: diciembre-2008
Mensajes: 17
Antigüedad: 16 años, 4 meses
Puntos: 0
Respuesta: Quien puede y me ayuda en Error Microsoft VBScript runtime error '800a01a8

segunda parte del codigo :


<%DO WHILE not RS2.eof%>
<tr>
<td><span style="font-size: 10px"><%=RS2("curso")%></span></td>
<td><span style="font-size: 10px"><%=RS2("fecha")%></span></td>
<td><span style="font-size: 10px"><%=RS2("profesor")%></span></td>
<td><span style="font-size: 10px"><%=RS2("observaciones")%></span></td>
<td><span style="font-size: 10px"><% if lcase(session("tipo")) = "admin" then%>
<%="<a href=/SIGISI/expedientes/seg_edit.asp?id=" & RS2("id") & " target=contents>(Editar)</a> <a href=/SIGISI/expedientes/seg_del.asp?id=" & RS2("id") & " target=contents>(Borrar)</a>" %>
<%else%>
<%="" %>
<% end if %></span></td>
</tr>
<%RS2.MOVENEXT
LOOP%>
<tr><td colspan="5"><br /><div align="right"><span style="font-size: 10px"><%="<a href=/SIGISI/expedientes/seg_add.asp?ficha=" & request.querystring("ID") & ">Agregar Curso</a>" %></span></div></td></tr>
</table>
<br />
<% set RS2=Server.CreateObject("ADODB.Recordset")
RS2.Open "SELECT id, curso, fecha, profesor, observaciones from exp_categoria WHERE ficha=" & request.querystring("ID") & " ORDER BY id ASC",conn,3,3
%>
<table width="95%" border="1" cellspacing="2" cellpadding="2">
<tr><td colspan="5"><div align="center" style="font-size: 14px"><strong><em>Cursos requeridos por categoría</em></strong></div></td>
</tr>
<tr>
<td><span style="font-size: 12px"><strong>Nombre</strong></span></td>
<td><span style="font-size: 12px"><strong>Fecha de Capacitaci&oacute;n </strong></span></td>
<td><span style="font-size: 12px"><strong>Qui&eacute;n imparti&oacute; </strong></span></td>
<td><span style="font-size: 12px"><strong>Observaciones</strong></span></td>
<td><span style="font-size: 12px">
<% if lcase(session("tipo")) = "admin" then%>
<%="<strong>Edición</strong>"%>
<%end if %>
</span></td>
</tr>
<%DO WHILE not RS2.eof%>
<tr>
<td><span style="font-size: 10px"><%=RS2("curso")%></span></td>
<td><span style="font-size: 10px"><%=RS2("fecha")%></span></td>
<td><span style="font-size: 10px"><%=RS2("profesor")%></span></td>
<td><span style="font-size: 10px"><%=RS2("observaciones")%></span></td>
<td><% if lcase(session("tipo")) = "admin" then%>
<%="<a href=/SIGISI/expedientes/cat_edit.asp?id=" & RS2("id") & ">(Editar)</a> <a href=/SIGISI/expedientes/cat_del.asp?id=" & RS2("id") & ">(Borrar)</a>" %>
<%else%>
<%="" %>
<% end if %> </td>
</tr>
<%RS2.MOVENEXT
LOOP%>
<tr><td colspan="5"><br /><div align="right"><%="<a href=/SIGISI/expedientes/cat_add.asp?ficha=" & request.querystring("ID") & ">Agregar Curso</a>" %></div></td></tr>
<tr>
</table>
<br>
<table border="1" cellpadding="2" cellspacing="2" width="95%">
<tr><td colspan="4"><div align="center" style="font-size: 14px"><strong><em>Cursos SEC AudioVisuales</em></strong></div></td>
<tr>
<td>Ficha</td>
<td>Calificación</td>
<td>Nombre del Curso</td>
<td>Fecha</td>
</tr>
<% While ((Repeat1__numRows <> 0) AND (NOT Recordset1.EOF)) %>
<tr>
<td><%=(Recordset1.Fields.Item("Ficha").Value)%> </td>
<td><%=(Recordset1.Fields.Item("Qualify").Value)%> </td>
<td><%=(Recordset1.Fields.Item("Difusion_Name").Va lue)%></td>
<td><%=(Recordset1.Fields.Item("Fecha").Value)%> </td>
</tr>
<%
Repeat1__index=Repeat1__index+1
Repeat1__numRows=Repeat1__numRows-1
Recordset1.MoveNext()
Wend
%>
</table>
<%else%>
No se encontró esa ficha<br>
</td>
</tr>
</tbody>
</table>

<%end if%>
</p>
<form action="/SIGISI/expedientes/index.asp" method="get" name="FormaFicha" target="contents">
Buscar otra ficha :<br />
<input type="text" name="ID" size="12"><input type="submit" value="Buscar">
</form>
<%end if%>
<%set RS2=Nothing
set RS4=Nothing
set RS3=Nothing
set RS=Nothing
%>
</body>
</html>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>
<%end if%>
  #3 (permalink)  
Antiguo 05/12/2008, 15:43
Avatar de JuanRAPerez
Colaborador
 
Fecha de Ingreso: octubre-2003
Mensajes: 2.393
Antigüedad: 21 años, 6 meses
Puntos: 27
Respuesta: Quien puede y me ayuda en Error Microsoft VBScript runtime error '800a01a8

juela!

mejor copia 3 lineas arriba de la 256 y tr4es abajo

con 7 lineas sabremos cual puede ser tu error y no con todo el codigo

suerte
__________________
JuanRa Pérez
San Salvador, El Salvador
  #4 (permalink)  
Antiguo 06/12/2008, 06:39
Avatar de Adler
Colaborador
 
Fecha de Ingreso: diciembre-2006
Mensajes: 4.671
Antigüedad: 18 años, 3 meses
Puntos: 126
Respuesta: Quien puede y me ayuda en Error Microsoft VBScript runtime error '800a01a8

Hola

Parece que estas intentado usar un objeto que ni tan siquiera has creado

'Set Recordset1 = Server.CreateObject("ADODB.Recordset")

Suerte
__________________
Los formularios se envían/validan con un botón Submit
<input type="submit" value="Enviar" style="background-color:#0B5795; font:bold 10px verdana; color:#FFF;" />
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 16:45.