Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

Evilkenzera

Um erro de BOF ou EOF????????

Recommended Posts

Estou com um problema aqui.

Tá dando esse erro:

ADODB.Field (0x80020009)

BOF ou EOF são verdadeiros, ou o registro atual foi excluído. A operação solicitada pelo aplicativo requer um registro atual.

Segue abaixo o código a página com o errro e a linha em destaque que com certeza apresenta o erro.

Alguém saberia me explicar o que é?

 

 

<!--#include file="connection/bib_conexao.asp"-->

<%

Dim Conexao, rsSubcategoria, strSQL, rsCategoria, strSQL2, varID

 

varID = Request.QueryString("cat")

strSQL = "SELECT * FROM subcategoria WHERE Cod_categoria = " & varID

strSQL2 = "SELECT * FROM Categoria ORDER BY Cod_categoria"

 

Call abre_conexao

Set rsSubcategoria = Conexao.Execute(strSQL)

Set rsCategoria = Conexao.Execute(strSQL2)

%>

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

<title>Untitled Document</title>

 

<style type="text/css">

<!--

body {

margin-left: 0px;

margin-top: 0px;

}

-->

</style>

<link href="estilo.css" rel="stylesheet" type="text/css" />

<style type="text/css">

<!--

.style1 {

font-family: Arial, Helvetica, sans-serif;

font-size: 11px;

}

.style3 {color: #ffffff}

.style4 {color: #FFFFFF}

-->

</style>

</head>

 

<body>

<table width="750" border="0" cellpadding="0" cellspacing="0">

<!--DWLayoutTable-->

<tr>

<td width="141" rowspan="4" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">

<!--DWLayoutTable-->

<tr>

<td width="10" height="516"> </td>

<td width="131" valign="top" cellpadding="2"><table width="128" border="0" align="right" cellpadding="0" cellspacing="0" bordercolor="#CCCCCC">

<%

While Not rsCategoria.EOF

%>

<tr bgcolor="#FFFFFF">

<td width="57%"><span class="style2"><a href="categoria.asp?cat=<%= rsCategoria("Cod_categoria")%>" class="menuverde"><%= rsCategoria("Categoria") %></b></a></span></td>

</tr>

<%rsCategoria.MoveNext

Wend

 

%>

</table></td>

</tr>

</table></td>

<td width="4" rowspan="5" valign="top"><img src="imagens/barra_vertical.gif" width="4" height="506" /></td>

<td width="400" height="100" valign="top"><img src="imagens/399x100_biscoito_2.jpg" width="400" height="100" /></td>

<td width="4"> </td>

<td width="201" valign="top" bgcolor="#0099CC"><!--DWLayoutEmptyCell--> </td>

</tr>

<tr>

<td height="1"></td>

<td></td>

<td></td>

</tr>

<tr>

<td height="27" colspan="3" valign="top"><img src="<%= rsCategoria("URL_Imagem_top") %>" /></td>

</tr>

<tr>

<td height="389" colspan="3" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">

<!--DWLayoutTable-->

<tr>

<td width="605" height="389" valign="top"><table width="550" border="0" align="center">

<tr>

<%

nCol = 4 'Quantidade de Colunas

a = 1

While Not rsSubcategoria.EOF

%>

<td width="115" height="56" align="left" valign="top"><table width="42" border="0" align="left" cellpadding="0" cellspacing="0">

<tr>

<td width="96"><div align="center"><img src="<%= rsSubcategoria("URL_Imagem_subcategoria") %>" /></div></td>

</tr>

<tr>

<td><div align="center"><span class="menuverde"><a href="lista_produtos.asp?subcat=<%= rsSubcategoria("Cod_subcategoria")%>" class="menuverde"><%= rsSubcategoria("subcategoria") %></a></span></div></td>

</tr>

</table></td>

<%

if a = nCol then

response.write("</tr><tr>")

a = 0

end if

a = a + 1

rsSubcategoria.MoveNext

Wend

 

Call fecha_conexao

Set rsSubcategoria = Nothing

Set rsCategoria = Nothing

 

%>

</tr>

</table></td>

</tr>

</table></td>

</tr>

<tr>

<td height="68"></td>

<td></td>

<td></td>

<td></td>

</tr>

<tr>

<td height="31"> </td>

<td> </td>

<td> </td>

<td> </td>

<td> </td>

</tr>

</table>

</body>

</html>

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.