"Alex Stevens" <al****************@gcc.co.uk> wrote in
news:uJ**************@TK2MSFTNGP12.phx.gbl:
I want to cleanly convert a boolean value to a bit value (1 or 0) in
vb.net.
I can:
Math.Abs(CInt(bolValue))
or:
cint(bolValue) * -1
However, I wondered if there was a built-in method.
The cleanest method is to make a function that does it. It will make your
code more readable as well.
Or does VB still have the IIF function?
--
Chad Z. Hower (a.k.a. Kudzu) -
http://www.hower.org/Kudzu/
"Programming is an art form that fights back"
ELKNews - Get your free copy at
http://www.atozedsoftware.com