ho inserito queste righe:
mi da questo errore:codice:%> [img]<%= Path_IMG & Img_NonDisponibile_G %>[/img] <% else while not rs.eof
Microsoft VBScript compilation error '800a040e'
'loop' without 'do'
/Default.asp, line 375
Loop
^
dove sbaglio?
codice:<% 'SI VISUALIZZA IL CONTENUTO DELLA STRINGA SQL 'ALL'INTERNO DELLA TABELLA PRIMA DEFINITA cont=1 Do While iRecordsShown < iPageSize And Not objRS.EOF Dim Rig, bg Rig = Rig + 1 If Rig Mod 2 = 0 then bg = "#E4E4E4" Else bg = "#ccccff" End if %> <% strSql="select top 1 * from FotoProdotti where idprodotto=" & objRS("id") & " order by id desc" 'response.write(strSql): response.end() set rs=conn.execute(strSql) dim path_foto path_foto="/public/" if not rs.eof then %> [img]<%= Path_IMG & Img_NonDisponibile_G %>[/img] <% else while not rs.eof nomeFoto = rs("nomeFoto") set rs=nothing strSql="select * from Utenti where id=(select iduser from user_prodotti where idprodotto=" & objRS("id") & ") " set rs=conn.execute(strSql) '---Assegno e stampo a video If Not rs.EOF Then nome = rs("nome") citta = rs("citta") indirizzo = rs("indirizzo") telefono = rs("telefono") email = rs("email") piva = rs("piva") end if rs.close set rs=nothing '***** calcolo il percorso dell'immagine da stampare dim path_img_to_display If path_foto & nomeFoto <> "" Then path_img_to_display = path_foto & nomeFoto Else path_img_to_display = Path_IMG & Img_NonDisponibile_G End If %> <tr> <td><% nomefoto="" Cont = Cont + 1 'POSIZIONAMENTO ALLA RIGA SUCCESSIVA DEL DB iRecordsShown = iRecordsShown + 1 objRS.MoveNext Loop 'PULIZIA DEGLI OGGETTI ADO objRS.Close Set objRS = Nothing %> <%End if%> <%If ipagecount <> 1 Then%></td> <td></td> <td></td> <td></td> <td></td> </tr> <tr> <td colspan="6"><font face="verdana" size="1" color="#000000"> <center>[ <%if iPageCurrent-2 > 0 and iPageCurrent > 2 then%> Prima <%end if%> <%if iPageCurrent > 1 then%> Precedente <%end if%> <%if iPageCount > 2 then if iPageCurrent-2 < 1 then da_pag = 1 else da_pag = iPageCurrent-2 if iPageCurrent+2 > iPageCount then fino_a_pag = iPageCount else fino_a_pag = iPageCurrent+2 else da_pag = 1 fino_a_pag = iPageCount end if%> <%for i = da_pag to fino_a_pag%> <%if i = iPageCurrent then%> <font color="black" size="2"><%=i%></font> <%else%> <%=i%> <%end if%> <%next%> <%if iPageCurrent > 0 and iPageCurrent < iPageCount then%> Successiva <%end if%> <%if iPageCurrent+1 < iPageCount then%> Ultima <%end if%> ]</center> </font></td> </tr> <tr> <td colspan="6"><font face="verdana" size="0.5" color="#333333"> <center> Pagina <font color="#000000"><%=iPageCurrent%></font> di <font color="#000000"><%=iPageCount%></font> </center> </font> <font face="verdana" size="0.5" color="#333333"> <%end if%> <% objConn.Close Set objConn = Nothing %> </font></p></td> </tr>

Rispondi quotando
VVoVe:
