Expressions

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there a list of expressions with examples somewhere

What I need for my form to do is this: I want a radial button to automatically be selected if the condition of two drop down menus meet a criteria. How would my expressions look

If [ItemA] = Yes & [ItemB] = Yes Then [ItemC] is checked?
 
If ... Then works only in VBA code. In SQL or in expressions in, for
example, the control source of a text box, you need to use the IIF()
function. The IIF() function takes three arguments, the condition to test,
the value to return if the condition evaluates to True, and the value to
return if the condition evaluates to False. So your example would look
something like ...

ItemC = IIF([ItemA] = True And [ItemB] = True, True, False)

Note also the expression uses the word 'And' and not the ampersand character
('&'). The ampersand is the string concatenation operator, used like so ...

? "Hello " & "World"
Hello World

--
Brendan Reynolds (MVP)

bill said:
Is there a list of expressions with examples somewhere?

What I need for my form to do is this: I want a radial button to
automatically be selected if the condition of two drop down menus meet a
criteria. How would my expressions look?
If [ItemA] = Yes & [ItemB] = Yes Then [ItemC] is checked?
 
Back
Top