Salve, posto il seguente codice trovato su un sito per la paginazione dei dati contenuti in un database:Quando lo provo, però, mi appare il messaggio:codice:<% Set objRecordset = Server.CreateObject("ADODB.Recordset") strConnection = "Provider=Microsoft.Jet.Oledb.4.0;data source=" & server.mappath("mdb-database/database.mdb") CONST RECORDMAX = 10 If Request.QueryString("page").Count > 0 Then intPageNum = CInt(Request.QueryString("page")) Else intPageNum = 1 End If With objRecordset .CursorType = adOpenForwardOnly .CursorLocation = adUseClient .LockType = adLockReadOnly .CacheSize = RECORDMAX .PageSize = RECORDMAX .Source = "SELECT * FROM archivio ORDER BY gruppo" .ActiveConnection = strConnection .Open Set .ActiveConnection = Nothing intTotalPages = .PageCount If NOT .EOF then .AbsolutePage = intPageNum arrData = .GetRows(RECORDMAX) intColsTot = Ubound(arrData,1) intRowsTot = Ubound(arrData,2) End If End With objRecordset.Close:Set objRecordset = Nothing For i = 0 To intRowsTot Response.Write " " For j = 0 To intColsTot Response.Write " "&arrData(j, i) Next Next Response.Write " " If intPageNum > 1 Then Response.Write( "<-- ") End If For i = 1 to intTotalPages If i = intPageNum Then Response.Write(" "&i&"") Else Response.Write(" "&i&"") End If Next If intPageNum < intTotalPages Then Response.Write( " -->") End If %>
ADODB.Recordset errore "800a0bb9'
Gli argomenti non sono di tipo valido, non sono compresi nell'intervallo consentito o sono in conflitto.
Come mai?
Grazie

Rispondi quotando