472,338 Members | 1,765 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,338 software developers and data experts.

Error Type: ADODB.Recordset (0x800A0BCD) Help!

All i am doing is trying to write info to a access database but iget this error

Error Type:
ADODB.Recordset (0x800A0BCD)
Either BOF or EOF is True, or the current record has been deleted. Requested operation requires a current record.
/AF_Load_Process_Registration.asp, line 40

here is my code:

<%
Response.Expires = -1000 'Makes the browser not cache this page
Dim objConn

'Connect to database (AF.mdb)
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open "Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=" & Server.Mappath("CommandCenter/Database/AF.mdb")

%>

<%
Dim strFirstName, strLastName, strEmail, nameArray, strPassword, strUserName
Dim strSubject
Dim strMessage
Dim Mailer
Dim vbcrlf
Dim strError, intErrorCount
Dim strUserID, temp1, temp2
vbcrlf = chr(13) & chr(10)
strFirstName = Request.Form("First Name")
strLastName = Request.Form("Last Name")
temp1 = Mid(strLastName,1,3)
temp2 = Mid(strFirstName,1,3)
strUserID = Session("UserName")

'Add User to Database
dim strSQL
strSQL = "SELECT * FROM Load;"
dim objRS
Set objRS = Server.CreateObject("ADODB.Recordset")
objRS.open strSQL, objConn, adOpenForwardOnly, adLockOptimistic,adCmdText

'objRS.AddNew
'objRS("TimeSubmit") = Now() <-----LINE 40
'objRS("UserName") = strUserID
objRS("Date Available") = Request.Form("date")
objRS("Origin City") = Request.Form("OC")
objRS("Origin St") = Request.Form("OS")
objRS("Destination") = Request.Form("DC")
objRS("Destination St") = Request.Form("DS")
objRS("Truck Type") = Request.Form("trucktype")
objRS("Load Size") = Request.Form("loadsize")
objRS("Length") = Request.Form("length")
objRS("Quantity") = Request.Form("quantity")
objRS("Comments") = Request.Form("comments")
objRS.Update
objRS.Close
set objRS = Nothing

Some please help, its a simple mitake i am making i know..i checkd the access table..that is fine..i did not spell anything..also the access table is arranged in the same order in which i am writing to it..ie col 1 is timesubmit, col2 is username...etc
May 1 '07 #1
2 2060
jhardman
3,406 Expert 2GB
Why is the addNew line commented out? Surely you need this line to execute correctly. Did you comment out those lines and then forget to put them back?

Jared
May 1 '07 #2
JamieHowarth0
533 Expert 512MB
Hey,

As a small PS to Jared's note - if the code still doesn't work, check that your IUSR_MACHINENAME account has write access to the database file in question. Personally, I'd also look at using an SQL INSERT INTO statement as I've had problems using the AddNew method. Subsequently, I tend to separate my processing and data sections so my SQL code deals exclusively with database stuff and my VBScript displays/manipulates it.

Hope this helps!

medicineworker
May 2 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Chuck | last post by:
Hi! I have a ASP page that generates an excel report. It works fine if there are records found, however, if no records are found I would like to...
1
by: Jack | last post by:
Hi, I am trying to add a new record to a main page. This page is the processing page to a form. However, I am getting the following error message:...
1
by: Robert | last post by:
Hello, Is there sombody who can tel me what kind of error this is, and how i can fix it. This is the error: ADODB.Field (0x800A0BCD)...
3
by: amitbadgi | last post by:
Hi I am converting an asp applicattion to asp.net, and I am getting an error as follows, Exception Details:...
1
by: Kosmös Pollard | last post by:
Hey guys, I'm rather new to access and can not seem to figure out what is wrong with this code I will post below...but first...it was working...
1
by: mudasserrafiq | last post by:
I am using following asp file default.asp <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <META http-equiv=Content-Type...
3
by: Kosmos | last post by:
Hey ya'll...I can't seem to figure out why I'm getting this error message, but it all started when I added the new line of code with the...
2
by: colesslow | last post by:
i have these asp files to edit a record in my sql server..but it can't be done. the error is Error Type: ADODB.Recordset (0x800A0E7D) The...
1
by: shivasusan | last post by:
Hi Friends! Please Help me! How i can solve this error? Please explain me, what is the error and how to solve? Error Type: ADODB.Recordset...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.