Link to home
Start Free TrialLog in
Avatar of davidcahan
davidcahanFlag for United States of America

asked on

Opposite Value of What CBool(Variable) evaluates to

How do i programmtically, in one line get the opposite value of what cbool is evaluating to.  So if Cbool(Var) = True, how would I write the code so that the value would be false.

An example of what i'm doing might help:
Application("VendorVisible") = True

ddlVendorID.visible = Cbool(Application("VendorVisible") )
ddlSalesSiteID.visible = -CBool(Application("VendorVisible"))

In this example if Application("VendorVisible") = true then the dropdownlist VendorID should be visible but the dropdownlist SalesSiteID should not.  I want to avoid an if/then statement.
ASKER CERTIFIED SOLUTION
Avatar of Dirk Haest
Dirk Haest
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of davidcahan

ASKER

perfect...thanks