Question for Ray @ where ever he may be.

J

Jeff Uchtman

Ray,
I followed your advice on an eariler question on CBool by using this to
check 3 true/false boxes:
<%
Dim A, B, C 'As Integer
Dim Check 'As Boolean
A = rs("PetA")
B = rs("PetB")
C = rs("PetC")
Check = CBool(A = B = C) ' Check is set to True.
%>

This works but really slows down access to the ms-sql db. Any advice Ray,
anyone?

Thanks
Jeff
 
E

Evertjan.

Jeff Uchtman wrote on 02 feb 2004 in
microsoft.public.inetserver.asp.general:
Check = CBool(A = B = C)

This cannot be usefull in vbs!

A = B = C

means

"give A the boolean value of the result of B = C"

but A = B = C is a statement, not a function,
so it should have no output in my view,
but vbs gives it a "false" output,
since M$ in their wisdom doen't want
any distinction between statement and function

===============

Check = CBool(A = B = C)
document.write Check

is like

Check = CBool(false)
document.write Check

or

document.write a=3

They all ALWAYS give FALSE !
 

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

Forum statistics

Threads
474,145
Messages
2,570,824
Members
47,369
Latest member
FTMZ

Latest Threads

Top