=?Utf-8?Q?What_is_equivalent_to_vb=E2=80=99s_IIF_f?==?Utf-8?Q?or_C#=3F?=

A

Ashton

object o;

o = (cond1 = cond2 ? truevalue : falsevalue);

Basically,

<bool condition> ? <true value> : <false value>;

Hope this helps

Ashton
 
J

Joyjit Mukherjee

you can do it like this: -

if a evaluates to 1 then the expression returns true, false otherwise

a == 1 ? true : false

regards
Joyjit
 

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
473,734
Messages
2,569,441
Members
44,832
Latest member
GlennSmall

Latest Threads

Top