Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Error code 80020009 "Exception Occured"

Thread Tools

Error code 80020009 "Exception Occured"

Posts: n/a
Hey guys, I'm back again....I've got the results displaying that I
wanted but instead of having a "next" or "previous" link displayed I
am getting the error msg below (I actually get the data that I'm
supposed to get meaning that my query seems to be working fine but
instead of making its way to the INCLUDE file (bottom navigation bar)
it displays the following error msg instead of the included nav bar...

error '80020009'
Exception occurred.

line 57

"Line 57" is the line that says

Response.Write "<b>Name :</b> " & rs("name")

(the start of my display)...

I think that it's having trouble figuring out what to do to "close up"
my recordset query....Can you take a look and let me know what I'm
doing wrong or any suggestions?

I searched thru all previous posts and couldn't find anything that
explained it sufficiently....I also found a post at <a
href="">ASP Faq's</a> that
explained to some degree so instead of "SELECT *" I input all the
corresponding columns in the database...Still no luck....

<!-- #INCLUDE VIRTUAL="/_borders/top_nav.asp" -->

Mode = request.form("mode")
Name = request.form("name")
Shift = request.form("shift")
Wave = request.form("wave")
Carton = request.form("carton")
Location = request.form("location")
License = request.form("license")
Sku = request.form("sku")
Qty = request.form("quantity")
Reason = request.form("reason")
Comments = request.form("comments")
Results = DateAdd("h", -1, Now())

'************************************************* ****************************
'************************************************* ****************************
'create db connection
Set dbconn = Server.CreateObject("ADODB.Connection")

'create recordset object
Set rs = Server.CreateObject("ADODB.Recordset")

'open db in a DSN-less method

If IsEmpty (Request.QueryString("pageNum")) Then
curPage = 1
curPage = CInt(Request.QueryString("pageNum"))
End If

'specify more info about rs
rs.CursorLocation = 3
rs.CursorType = 3
rs.PageSize = 3 "shortage", dbconn

'sql statement to return input values drawn from html fields within
previous week
SQLqry = "SELECT name, shift, wave, carton, location, license, sku,
qty, reason, comments, date FROM shortage WHERE date >= #" & Results &
"# ORDER BY date"

'display results of statement on screen for debugging
'Response.Write "<h3><b><u>" & (SQLqry) & "</u></b></h3><br>"

rs.Open SQLqry

If Not rs.EOF Then
rs.AbsolutePage = curPage
Response.Write "<p>You are on page: " & curPage & " of " &
Response.Write "<br>"
Response.Write "<br>"

For i = 1 to rs.PageSize
Response.Write "<b>Name :</b> " & rs("name")
Response.Write "<br>"
Response.Write "<b>Shift :</b> " & rs("shift")
Response.Write "<br>"
Response.Write "<b>Wave Number :</b> " & rs("wave")
Response.Write "<br>"
Response.Write "<b>Carton Number :</b> " & rs("carton")
Response.Write "<br>"
Response.Write "<b>Location :</b> " & rs("location")
Response.Write "<br>"
Response.Write "<b>License :</b> " & rs("license")
Response.Write "<br>"
Response.Write "<b>SKU :</b> " & rs("sku")
Response.Write "<br>"
Response.Write "<b>Quantity :</b> " & rs("qty")
Response.Write "<br>"
Response.Write "<b>Reason :</b> " & rs("reason")
Response.Write "<br>"
Response.Write "<b>Comments :</b> " & rs("comments")
Response.Write "<br>"
Response.Write "<b>Date Submitted :</b> " & rs("date")
Response.Write "<hr>"

ElseIf rs.EOF Then
Response.Write "<h3><b>I'm sorry but no records were found matching
that description!</b></h3>"
End If

If curPage > 1 then
Response.Write "<a href='search_results_hour.asp?pageNum=" &
curPage-1 & "'>Previous</a>"
If curPage < rs.PageCount then
Response.Write " | "
end if
end if
If curPage < rs.PageCount then
Response.Write "<a href='search_results_hour.asp?pageNum=" &
curPage+1 & "'>Next</a>"
end if

'close recordset

'zero out recordset object
Set rs = Nothing

'smack around the db connection until it lets go

'terminate db connection with extreme prejudice
set dbconn = nothing

Response.Write "<br><a href='../Archives.asp'>Return to Archives</a>"
Response.Write "<br><a href='../../Shortage.asp'>Return to Shortage
Submission Form</a>"
Response.Write "<br><a href='../../../default.asp'>Return to Warehouse
%><!-- #INCLUDE VIRTUAL="/_borders/bottom_nav.asp" -->
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Error code 80020009 "Exception Occured" dmiller23462 ASP General 2 08-18-2004 03:40 PM
CDONTS.NewMail.1 error '80020009' unable to connect to server Chris ASP General 1 08-05-2004 05:54 PM
ADSI 80020009 Error on windows 2003 M Naeem Baig ASP General 0 06-14-2004 12:43 PM
error '80020009' Exception occurred psaban ASP General 0 06-10-2004 03:35 PM
ADODB.Field error '80020009 olivier Micheli ASP General 0 08-15-2003 07:43 AM