View Single Post
 
Old October 22nd, 2004, 04:48 PM
deepa12 deepa12 is offline
Registered User
 
Join Date: Oct 2004
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default ADODB.Recordset (0x800A0BB9)

Hi,
     I am getting this Error

Error Type:
ADODB.Recordset (0x800A0BB9)
Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
/khandkeOnline/Images/classified/AddUser.asp, line 9

below is my code,I tried all combination of locktype but it gives this error everytime.I can retrive the data easily from the database just can't insert any record. Please help... This is the example from chapter 15.


AddUser.asp

<%
dim rsUsers
set rsUsers=Server.CreateObject("ADODB.Recordset")
SQL_str="Select * from Person where E_Mail='" & Session("E_Mail") & "' and Pword='" & Session("FormPass") & "'"
rsUsers.Open SQL_str, objConn,adOpenForwardOnly, adLockOptimistic, adCmdTable --> shows Error on this line

if Session("PersonId") <> " " then
  rsUsers.Filter="PersonId= '" & Session("PersonId") & "'"
 else
  rsUsers.Filter="E_Mail= '" & Request.Form("E_Mail") & "'" & "AND Pword= '" & Request.Form("FormPass") & "'"
   if rsUsers.EOF then
    rsUsers.AddNew
    'else
    ' Email, Password Matches with DB
    end if
 end if

rsUsers("E_Mail") =Request.Form("E_Mail")


Clssfd.asp


<%
 Option Explicit
 Dim objConn
 set objConn= Server.CreateObject("ADODB.Connection")
 objConn.Open "Provider=Microsoft.Jet.OLEDB.4.0; " & "Data Source=C:\Inetpub\wwwroot\khandkeProj\Images\Class ified\ClassData.mdb"

 if Session("blnValidUser")= True and Session("PersonId") = "" then
  Dim rsPersonIdCheck
  set rsPersonIdCheck=Server.CreateObject("ADODB.Records et")
  Dim strSQL
  strSQL="select PersonId from Person where E_Mail= '" & Session("E_Mail") & "';"
  rsPersonIdCheck.Open strSQL, objConn
  if rsPersonIdCheck.EOF Then
    Session("blnValidUser")= False
  else
    Session("PersonId") =rsPersonIdCheck("PersonId")
  End if
  rsPersonIdCheck.Close
  set rsPersonIdCheck = Nothing
 End if
%>