Visualizzazione dei risultati da 1 a 9 su 9
  1. #1
    Utente di HTML.it L'avatar di fazius
    Registrato dal
    Mar 2006
    residenza
    Torino
    Messaggi
    870

    ADODB.Recordset error '800a0bb9'

    ciao a tutti sto provando a montare una specie di cms e mi da questo errore
    ADODB.Recordset error '800a0bb9'
    Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
    /engine/default.asp, line 5

    cercando in rete credo di aver capito che c'è un incompatibilita nella compilazione del codice "credo" io posto il codice per verificare se è questo il problema
    <%@LANGUAGE="VBSCRIPT"%>

    <%
    set rsCat = Server.CreateObject("ADODB.Recordset")
    rsCat.ActiveConnection = MM_connDUdirectory_STRING
    rsCat.Source = "SELECT *, (SELECT COUNT (*) FROM LINKS WHERE LINKS.CAT_ID = CATS.CAT_ID) AS LINK_COUNT FROM CATS ORDER BY CAT_NAME ASC"
    rsCat.CursorType = 0
    rsCat.CursorLocation = 2
    rsCat.LockType = 3
    rsCat.Open()
    rsCat_numRows = 0
    %>
    <%
    set rsSub = Server.CreateObject("ADODB.Recordset")
    rsSub.ActiveConnection = MM_connDUdirectory_STRING
    rsSub.Source = "SELECT * FROM SUBS ORDER BY SUB_NAME ASC"
    rsSub.CursorType = 0
    rsSub.CursorLocation = 2
    rsSub.LockType = 3
    rsSub.Open()
    rsSub_numRows = 0
    %>
    <%
    set rsHot = Server.CreateObject("ADODB.Recordset")
    rsHot.ActiveConnection = MM_connDUdirectory_STRING
    rsHot.Source = "SELECT *, (LINK_RATE/NO_RATES) AS RATING FROM LINKS WHERE LINK_APPROVED = Yes ORDER BY NO_HITS DESC"
    rsHot.CursorType = 0
    rsHot.CursorLocation = 2
    rsHot.LockType = 3
    rsHot.Open()
    rsHot_numRows = 0
    %>
    <%
    set rsNew = Server.CreateObject("ADODB.Recordset")
    rsNew.ActiveConnection = MM_connDUdirectory_STRING
    rsNew.Source = "SELECT * FROM LINKS WHERE LINK_APPROVED = Yes ORDER BY LINK_DATE DESC"
    rsNew.CursorType = 0
    rsNew.CursorLocation = 2
    rsNew.LockType = 3
    rsNew.Open()
    rsNew_numRows = 0
    %>
    <%
    Dim HLooper1__numRows
    HLooper1__numRows = -2
    Dim HLooper1__index
    HLooper1__index = 0
    rsCat_numRows = rsCat_numRows + HLooper1__numRows
    %>
    <%
    ' *** Go To Record and Move To Record: create strings for maintaining URL and Form parameters

    ' create the list of parameters which should not be maintained
    MM_removeList = "&index="
    If (MM_paramName <> "") Then MM_removeList = MM_removeList & "&" & MM_paramName & "="
    MM_keepURL="":MM_keepForm="":MM_keepBoth="":MM_kee pNone=""

    ' add the URL parameters to the MM_keepURL string
    For Each Item In Request.QueryString
    NextItem = "&" & Item & "="
    If (InStr(1,MM_removeList,NextItem,1) = 0) Then
    MM_keepURL = MM_keepURL & NextItem & Server.URLencode(Request.QueryString(Item))
    End If
    Next

    ' add the Form variables to the MM_keepForm string
    For Each Item In Request.Form
    NextItem = "&" & Item & "="
    If (InStr(1,MM_removeList,NextItem,1) = 0) Then
    MM_keepForm = MM_keepForm & NextItem & Server.URLencode(Request.Form(Item))
    End If
    Next

    ' create the Form + URL string and remove the intial '&' from each of the strings
    MM_keepBoth = MM_keepURL & MM_keepForm
    if (MM_keepBoth <> "") Then MM_keepBoth = Right(MM_keepBoth, Len(MM_keepBoth) - 1)
    if (MM_keepURL <> "") Then MM_keepURL = Right(MM_keepURL, Len(MM_keepURL) - 1)
    if (MM_keepForm <> "") Then MM_keepForm = Right(MM_keepForm, Len(MM_keepForm) - 1)

    ' a utility function used for adding additional parameters to these strings
    Function MM_joinChar(firstItem)
    If (firstItem <> "") Then
    MM_joinChar = "&"
    Else
    MM_joinChar = ""
    End If
    End Function
    %>



    <%
    If giEnabled Then
    DoPageHeader
    %>

    <table cellspacing="10">
    <tr align="center" valign="top">
    <td align="left">
    <table>
    <%
    startrw = 0
    endrw = HLooper1__index
    numberColumns = 2
    numrows = -1
    while((numrows <> 0) AND (Not rsCat.EOF))
    startrw = endrw + 1
    endrw = endrw + numberColumns
    %>
    <tr align="center" valign="top">
    <%
    While ((startrw <= endrw) AND (Not rsCat.EOF))
    %>
    <td>
    <table border="0" cellspacing="2" cellpadding="1" width="305">
    <tr align="left" valign="top">
    <td valign="middle"><div class = "links"> <font face="Verdana, Arial, Helvetica, sans-serif" size="3">"><%=(rsCat.Fields.Item("CAT_NAME").Value)%> <font size="2">(<%=(rsCat.Fields.Item("LINK_COUNT").Valu e)%>)</font></font>


    <%
    Dim Repeat1__numRows
    Repeat1__numRows = 3
    Dim Repeat1__index
    Repeat1__index = 0
    rsSub_numRows = rsSub_numRows + Repeat1__numRows
    varID = rsCat.Fields.Item("CAT_ID").Value
    rsSub.Filter = "CAT_ID = " & varID
    %>
    <%
    Dim Repeat2__numRows
    Repeat2__numRows = 5
    Dim Repeat2__index
    Repeat2__index = 0
    rsHot_numRows = rsHot_numRows + Repeat2__numRows
    %>
    <%
    Dim Repeat3__numRows
    Repeat3__numRows = 5
    Dim Repeat3__index
    Repeat3__index = 0
    rsNew_numRows = rsNew_numRows + Repeat3__numRows
    %>
    <% While ((Repeat1__numRows <> 0) AND (NOT rsSub.EOF)) %>
    <font face="Verdana, Arial, Helvetica, sans-serif"> <font size="1">&subid=<%=(rsSub.Fields.Item("SUB_ID").Value)%>">< %=(rsSub.Fields.Item("SUB_NAME").Value)%></font></font>
    <% If Repeat1__index-1 > 0 Then %>
    <font face="Verdana, Arial, Helvetica, sans-serif">
    <font size="1">...</font></font>
    <% Else %>
    <font face="Verdana, Arial, Helvetica, sans-serif">
    <font size="1">, </font></font>
    <% End If %>
    <%
    Repeat1__index=Repeat1__index+1
    Repeat1__numRows=Repeat1__numRows-1
    rsSub.MoveNext()
    Wend
    %>

    </div></td>
    </tr>
    </table>
    </td>
    <%
    startrw = startrw + 1
    rsCat.MoveNext()
    Wend
    %>
    </tr>
    <%
    numrows=numrows-1
    Wend
    %>
    </table>
    </td>
    </tr>
    </table>
    </td>
    </tr>
    <tr>
    <td align="left" valign="top"></td>
    </tr>
    <tr>
    <td align="center" valign="top">
    <table border="0" cellspacing="3" cellpadding="3">
    <tr align="center" valign="middle">
    <td valign="top" align="right">
    <table border="0" cellspacing="1" cellpadding="3" bgcolor="#009999" width="305">
    <tr bgcolor="#00CC66" valign="middle" align="center">
    <td colspan="3"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><font color="#FFFFFF">Ãîðÿ÷èå ññûëêè</font></font></td>
    </tr>
    <tr bgcolor="#CCCCCC" valign="middle" align="center">
    <td><font face="Verdana, Arial, Helvetica, sans-serif" size="1" color="#000000">Íàçâàíèå ñàéòà</font></td>
    <td width="30"><font face="Verdana, Arial, Helvetica, sans-serif" size="1" color="#000000">Õèòîâ</font></td>
    <td width="58"><font face="Verdana, Arial, Helvetica, sans-serif" size="1" color="#000000">Ðåéòèíã</font></td>
    </tr>
    <%
    While ((Repeat2__numRows <> 0) AND (NOT rsHot.EOF))
    %>
    <tr bgcolor="#FFFFFF" valign="middle" align="left">
    <td><div class = "links"><font face="Verdana, Arial, Helvetica, sans-serif" size="1">&url=<%=(rsHot.Fields.Item("LINK_URL").Value)%> " target="_blank" onclick="window.location.reload(true);"><%=(rsHot. Fields.Item("LINK_NAME").Value)%></font></div></td>
    <td align="center"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><%=(rsHot.Fields.Item("NO_HITS").Value)%> </font></td>
    <td align="center"><font face="Verdana, Arial, Helvetica, sans-serif" size="1">[img]assets/<%= FormatNumber((rsHot.Fields.Item([/img].gif" align="absmiddle">
    </font></td>
    </tr>
    <%
    Repeat2__index=Repeat2__index+1
    Repeat2__numRows=Repeat2__numRows-1
    rsHot.MoveNext()
    Wend
    %>
    </table>
    </td>
    <td valign="top" align="left">
    <table border="0" cellspacing="1" cellpadding="3" bgcolor="#009999" width="305">
    <tr bgcolor="#00CC66" valign="middle" align="center">
    <td colspan="2"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><font color="#FFFFFF">Íîâûå ññûëêè</font></font></td>
    </tr>
    <tr bgcolor="#CCCCCC" valign="middle" align="center">
    <td><font face="Verdana, Arial, Helvetica, sans-serif" size="1" color="#000000">Íàçâàíèå ñàéòà</font></td>
    <td width="60"><font face="Verdana, Arial, Helvetica, sans-serif" size="1" color="#000000">Äàòà</font></td>
    </tr>
    <%
    While ((Repeat3__numRows <> 0) AND (NOT rsNew.EOF))
    %>
    <tr bgcolor="#FFFFFF" valign="middle" align="left">
    <td><div class = "links"> <font face="Verdana, Arial, Helvetica, sans-serif" size="1">&url=<%=(rsNew.Fields.Item("LINK_URL").Value)%> " target="_blank" onclick="window.location.reload(true);"><%=(rsNew. Fields.Item("LINK_NAME").Value)%></font></div></td>
    <td align="center"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><%=(rsNew.Fields.Item("LINK_DATE").Value) %></font></td>
    </tr>
    <%
    Repeat3__index=Repeat3__index+1
    Repeat3__numRows=Repeat3__numRows-1
    rsNew.MoveNext()
    Wend
    %>
    </table>
    </td>
    </tr>
    </table>

    <%
    DoPageFooter
    Else
    Response.Redirect "W3Disabled.asp"
    End If
    %>
    <%
    rsCat.Close()
    %>
    <%
    rsSub.Close()
    %>
    <%
    rsHot.Close()
    %>
    <%
    rsNew.Close()
    %>

    questa è la connessione

    '<%
    ' FileName="Connection_ado_conn_string.htm"
    ' Type="ADO"
    ' HTTP="false"
    ' Catalog=""
    ' Schema=""
    MM_ConAlbum_STRING = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & server.mapPath("mdb-database/DUdirectory.mdb")
    %>
    unadomanda per voi banale ma il file (FileName="Connection_ado_conn_string.htm")
    è virtuale ho deve esserci una string.htm? scusate l'ignoranza ciao a tutti
    lunga vita e prosperità

  2. #2
    Lo stai provando online o in locale?
    Quale è la riga 5 del file default.asp?

  3. #3
    Utente di HTML.it L'avatar di fazius
    Registrato dal
    Mar 2006
    residenza
    Torino
    Messaggi
    870
    ciao, lo sto provando online
    la riga 5 è
    rsCat.ActiveConnection = MM_connDUdirectory_STRING
    grazie
    lunga vita e prosperità

  4. #4
    Prova a cambiare la connessione in questo modo:
    codice:
    MM_connDUdirectory_STRING= "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & server.mapPath("/mdb-database/DUdirectory.mdb")

  5. #5
    Utente di HTML.it L'avatar di fazius
    Registrato dal
    Mar 2006
    residenza
    Torino
    Messaggi
    870
    Grandissimo!!!!
    grazie infinite funziona, al primo colpo hai fatto centro
    Ciao
    lunga vita e prosperità

  6. #6

  7. #7
    Ciao a tutti,

    scusate se riesumo un 3d un pò vecchio ma anche io ho lo stesso problema.

    l'errore era sula riga 14 cioè:

    MM_rsUser.ActiveConnection = MM_miaconnessione_STRING;
    che ho sostituito con:

    MM_miaconnessione_STRING="Provider=Microsoft.Jet.O LEDB.4.0; Data Source=" & Server.MapPath("/mdb-database/miodb.mdb");
    ora però l'errore si è spostato alla riga 21 e cioè:

    MM_rsUser.Open();
    Perchèèèèèèè??????
    Il Mondo è Bello perché è Avariato !!!

  8. #8
    Scusate, ma prima ho scritto una ca---ta... :berto:
    Però il problema rimane...

    Io ho una pagina per il log in con questo codice:

    <%@LANGUAGE="JAVASCRIPT" CODEPAGE="1252"%>

    <%
    // *** Validate request to log in to this site.
    var MM_LoginAction = Request.ServerVariables("URL");
    if (Request.QueryString!="") MM_LoginAction += "?" + Server.HTMLEncode(Request.QueryString);
    var MM_valUsername=String(Request.Form("utente"));
    if (MM_valUsername != "undefined") {
    var MM_fldUserAuthorization="";
    var MM_redirectLoginSuccess="inelmo.asp";
    var MM_redirectLoginFailed="errato.html";
    var MM_flag="ADODB.Recordset";
    var MM_rsUser = Server.CreateObject(MM_flag);
    MM_rsUser.ActiveConnection = MM_connessioneborselli_STRING;
    MM_rsUser.Source = "SELECT Utente, Password";
    if (MM_fldUserAuthorization != "") MM_rsUser.Source += "," + MM_fldUserAuthorization;
    MM_rsUser.Source += " FROM login WHERE Utente='" + MM_valUsername.replace(/'/g, "''") + "' AND Password='" + String(Request.Form("pwd")).replace(/'/g, "''") + "'";
    MM_rsUser.CursorType = 0;
    MM_rsUser.CursorLocation = 2;
    MM_rsUser.LockType = 3;
    MM_rsUser.Open();
    if (!MM_rsUser.EOF || !MM_rsUser.BOF) {
    // username and password match - this is a valid user
    Session("MM_Username") = MM_valUsername;
    if (MM_fldUserAuthorization != "") {
    Session("MM_UserAuthorization") = String(MM_rsUser.Fields.Item(MM_fldUserAuthorizati on).Value);
    } else {
    Session("MM_UserAuthorization") = "";
    }
    if (String(Request.QueryString("accessdenied")) != "undefined" && false) {
    MM_redirectLoginSuccess = Request.QueryString("accessdenied");
    }
    MM_rsUser.Close();
    Response.Redirect(MM_redirectLoginSuccess);
    }
    MM_rsUser.Close();
    Response.Redirect(MM_redirectLoginFailed);
    }
    %>
    Ma non funziona, mi dà questo errore:

    ADODB.Recordset (0x800A0BB9)
    Gli argomenti non sono di tipo valido, non sono compresi nell'intervallo consentito o sono in conflitto.
    /borselli/login.asp, line 14

    Perchè?
    Il Mondo è Bello perché è Avariato !!!

  9. #9
    Utente di HTML.it L'avatar di wegawhite
    Registrato dal
    Aug 2004
    Messaggi
    1,400
    Ciao.

    Sto provando ad utilizzare lo stesso tuo script; sei risucito a farlo funzionare?

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.