Ok,

I get this error (db is Access):

error '80020009'

/wholesale/o12register.asp, line 22

*************************************
<%
If request("Page") = "2" Then

        SQL = "SELECT * FROM Users WHERE Username='" &
request("Username") & "'"
        Set RS = Server.CreateObject("ADODB.Recordset")
        RS.Open SQL, Conn, 1, 3
        
        If NOT (RS.BOF AND RS.EOF) Then
                Response.redirect "o12register.asp?Username=" &
request("Username") & "&Name=" & request("Name") &
"&Email=" & request("Email") &
"&Error=Username&AreaID=" & request("AreaID")
        End If
        
        RS.Close
        Set RS = Nothing
        
        
        SQL = "SELECT * FROM Areas WHERE AreaID=" &
request("AreaID")
        Set RS = Server.CreateObject("ADODB.Recordset")
        RS.Open SQL, Conn, 1, 3
        
22.     If NOT RS("AllowRegister") Then
                Response.redirect "o12register.asp?Username=" &
request("Username") & "&Name=" & request("Name") &
"&Email=" & request("Email") &
"&Error=AllowRegister&AreaID=" & request("AreaID")
        End If
        
        ApprovalRequired = RS("ApprovalRequired")
        LoginUrl = RS("LoginUrl")
        
        If RS("NotifyWhenRegister") Then
                varTo = RSBODY("FromEmail")
                varFrom = RSBODY("FromEmail")
                varEmailComp = RSBODY("EmailComp")
                varSMTPServer = RSBODY("SMTPServer")
                varPasswordEmailSubject = "A new user has
registered."
                varBody = "A new user has registered for access to
your protected area."
                Call sendMail(varTo, varFrom, varEmailComp,
varSMTPServer, varBody, varPasswordEmailSubject)
        End If
        
        RS.Close
        Set RS = Nothing


        Set RS = Server.CreateObject("ADODB.Recordset")
        RS.Open "Users", Conn, 2, 2
        RS.addnew
        RS("Name") = request("Name")
        RS("Username") = request("Username")
        RS("Password") = request("Password")
        RS("Email") = request("Email")
        RS("ExpDate") = "999999999"

        If ApprovalRequired Then
                RS("Status") = "Pending"
        Else
                RS("Status") = "Active"
        End If
        
        RS.update
        RS.close
        
        SQL = "SELECT UserID FROM Users ORDER BY UserID DESC"
        RS.Open SQL, Conn, 1, 3
        UserID = RS("UserID")
        RS.Close
        
        RS.Open "UserArea", Conn, 2, 2
        RS.addnew
        RS("UserID") = UserID
        RS("AreaID") = request("AreaID")
        RS.update
        RS.close
        
        Set RS = Nothing
        
        Response.redirect "o12register.asp?Page=3&LoginUrl="
& LoginURL
End If
%>

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


------------------------ Yahoo! Groups Sponsor --------------------~--> 
Most low income households are not online. Help bridge the digital divide today!
http://us.click.yahoo.com/cd_AJB/QnQLAA/TtwFAA/saFolB/TM
--------------------------------------------------------------------~-> 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to