Print Page | Close Window

Exception occurred -

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=5022
Printed Date: 30 March 2026 at 7:46pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Exception occurred -
Posted By: Greaser
Subject: Exception occurred -
Date Posted: 14 August 2003 at 9:56am
I think what I am trying to do is pretty simple.


<%
if rsPass("seconds") <> " " then
response.write "Sorry.  There is no test pass with this is. Please contact <a href=mailto:mail@somesome>"
end if
%>    

If rsPass is null then I want to display the message.  

Am I even close in my coding?

I get when using it.
 Error Type:
(0x80020009)
Exception occurred.
/lab/sql/pass.asp, line 192


-------------
'Computers don't make errors...what they do, they do on purpose.' - Dale Gribble



Replies:
Posted By: MorningZ
Date Posted: 14 August 2003 at 10:32am
what code is at line 192?

-------------
Contribute to the working anarchy we fondly call the Internet


Posted By: Greaser
Date Posted: 14 August 2003 at 10:44am
if rsPass("seconds") <> " " then

-------------
'Computers don't make errors...what they do, they do on purpose.' - Dale Gribble


Posted By: pmormr
Date Posted: 14 August 2003 at 4:04pm

try replacing

if rsPass("seconds") <> " " then

with

if rsPass("seconds") = "" then



-------------
Paul A Morgan

http://www.pmorganphoto.com/" rel="nofollow - http://www.pmorganphoto.com/


Posted By: 3BEPb
Date Posted: 16 August 2003 at 9:37pm
pmormr, rsPass("seconds")<>"" doesn't mean Null AFAIK. That means just blank record, which is NOT NULL anyway.


Posted By: pmormr
Date Posted: 17 August 2003 at 3:43pm

i said try, and btw, that line should work. He used the wrong word to describe his situation, from what i picked up in that code, if there's nothing in seconds then he wants to display the message. Look at the blue text a little bit closer, notice that it sayes '=' not '<>'!

P.S. I know a good anger therapist!



-------------
Paul A Morgan

http://www.pmorganphoto.com/" rel="nofollow - http://www.pmorganphoto.com/


Posted By: 3BEPb
Date Posted: 17 August 2003 at 9:51pm

pmormr, lol :)

I prefer build, not destroy, so I never angry. If you think abt caps in "NOT NULL", sorry, but that's the way how I highlite values in code :))))



Posted By: ljamal
Date Posted: 17 August 2003 at 10:26pm
The best way to detect null is the IsNull function, so try:

<%
if IsNull(rsPass("seconds")) then
response.write "Your Message"
end if
%>    



-------------
L. Jamal Walton

http://www.ljamal.com/" rel="nofollow - L. Jamal Inc : Web/ Print Design and ASP Programming



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net