Buongiorno a tutti, vi riporto un problema (da amatore) che non riesco a risolvere:
Ho una connessione al database che con un ciclo mi fa vedere tutte le righe contenute in una tabella come per esempio:
All'interno della stessa devo fare una connessione alla query per pubblicare il voto delle fotografie già votate oppure farmi apparire il bottone VOTA se come utente devo ancora votarle:codice:<%Set oConn=Server.CreateObject("ADODB.Connection")oConn.Open "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=" & Request.ServerVariables("APPL_PHYSICAL_PATH") & "mdb-database\concorso.mdb" sql="SELECT * FROM tb_foto ORDER by ft_titolo"Set oRs = Server.CreateObject("ADODB.Recordset")Set oRs = oConn.Execute(sql)%> <%=oRs("ft_titolo")%>
A questo punto tutto bene, vicino al titolo mi stampa il voto e non mi fa visualizzare il bottone VOTA... solo che non passa alla riga successiva in quanto mi restituisce l'errorecodice:<%Set oConn=Server.CreateObject("ADODB.Connection")oConn.Open "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=" & Request.ServerVariables("APPL_PHYSICAL_PATH") & "mdb-database\concorso.mdb" sql="SELECT * FROM tb_foto LEFT JOIN tb_votazione ON tb_foto.id_foto = tb_votazione.vt_foto WHERE tb_votazione.vt_idutente=" & session("idgiuria") Set oRs = Server.CreateObject("ADODB.Recordset") Set oRs1 = oConn.Execute(sql) voto="" %> <% if oRs1("vt_01")<>voto then Response.write (oRs1("vt_01")) Else %> <span style="font-size: 7pt"><font face="Verdana"><input type="submit" value="Vota!" name="B2"></font></span></td></form> <% end if autore=oRs1("vt_01") %> <% oRs1.close %>
Qualche aiutino per poter procedere con la riga successiva?codice:ADODB.Recordset error '800a0cc1' Item cannot be found in the collection corresponding to the requested name or ordinal /fotoscribaconcorso/admin/00_home.asp, line 229
Grazie mille!


Rispondi quotando