Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What is wrong in this code ?
Message
Information générale
Forum:
Internet
Catégorie:
Active Server Page
Divers
Thread ID:
00561454
Message ID:
00566843
Vues:
29
Dave
I am getting error HTTP500 ......
the code is not working:

Set myConn = Server.CreateObject("ADODB.Connection")
myConnStr = "DSN=2bs-GuestBook"
myConn.Open myConnStr

mySql = "SELECT * FROM GuestBook WHERE 0=1"

Set rstGuestBook = Server.CreateObject("ADODB.Recordset")
rstGuestBook.ActiveConnection = myConn
rstGuestBook.CursorLocation = adUseCleint
rstGuestBook.CursorType = adOpenStatic
rstGuestBook.LockType = adLockOptimistic
rstGuestBook.Open mySql

when I tracke it, it's giving me error on these 2 lines :
rstGuestBook.CursorLocation = adUseCleint
rstGuestBook.LockType = adLockOptimistic

what do you advice Dave?

Thanks again


>Open your recordset as a static, client side recordset and everything will be ok! Check the properties of the recordset. You *cannot* use the execute method of the connection object.
>
>set ors=server.createobject("adodb.recordset")
>>ors.cursorlocation = adUseClient
>>ors.CursorType = adOpenStatic
>>ors.LockType = adLockOptimistic
>ors.open ...
>
>-Dave
<><><><><><><><><><><><><><><><><><><><>
<><> REMEMBER,,,,KNOWLEDGE IS POWER <><>
<><><><><><><><><><><><><><><><><><><><>
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform