Unexpected Exception.

D

Devin

Hi,
I'm getting an exception error on this line:

do while not rs.eof and ucase(rs.fields("category")) =
ucase(holdLast)


This error occurs on the last record in the table (mdb). I deleted
the last few records from the table to see if it was something with
the record. The same thing occured.


I also response.write the values of rs.fields("category") and
holdLast and they output the values I would expect.


Am I going nuts?

I don't want to post my enter page, but if the error could really go
beyond this line then please let me know.

Thanks for any input.


DC
 
D

Devin

Hi,
I'm getting an exception error on this line:

do while not rs.eof and ucase(rs.fields("category")) =
ucase(holdLast)

This error occurs on the last record in the table (mdb).  I deleted
the last few records from the table to see if it was something with
the record.  The same thing occured.

I also response.write the values of  rs.fields("category") and
holdLast and they output the values I would expect.

Am I going nuts?

I don't want to post my enter page, but if the error could really go
beyond this line then please let me know.

Thanks for any input.

DC

It was unrelated. This post can be deleted :)
 
B

Bob Barrows

Both expressions are evaluated. If EOF is true, then
rs.fields("category") will raise an error.
Change it to:
do while not rs.eof
if ucase(rs.fields("category")) =ucase(holdLast) then
end if
rs.movenext
loop
 
B

Bob Barrows

Devin said:
Hi,
I'm getting an exception error on this line:

do while not rs.eof and ucase(rs.fields("category")) =
ucase(holdLast)
Oops, I should have written:

do while not rs.eof
if ucase(rs.fields("category")) =ucase(holdLast) then
...
else
break
end if
rs.movenext
loop
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,776
Messages
2,569,603
Members
45,189
Latest member
CryptoTaxSoftware

Latest Threads

Top