I have a linked excel table...
Several columns show the numbers 1-3 and I would like to know how to write a statement to display Yes, No, or Moreinfo.
I don't want the data altered in the table, I just want it to show differently in the form.
I have a linked excel table...
Several columns show the numbers 1-3 and I would like to know how to write a statement to display Yes, No, or Moreinfo.
I don't want the data altered in the table, I just want it to show differently in the form.
Expression in query or textbox:
Choose([fieldname], "Yes", "No", "More Info")
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
How will it know to display Yes if the data entry is 3, etc.
Search Access Help for specifics about Choose() function (might also look into Switch()). The number value in [field name] corresponds to the position of the choices.
If you want 3 to be Yes, 2 is No and 1 is More:
Choose([field name], "More Info", "No", "Yes")
However, the function will error if [field name] is null. If that is a possibility:
Choose(Nz([field name],0), "More Info", "No", "Yes")
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.