issue with row source of listbox

  • Thread starter Thread starter Associates
  • Start date Start date
A

Associates

Hi,

I need help with the following issue.

In the form, i have a listbox whose row source made up of two different
tables.
In one of the field i set it up as follows

Expr1: IIf(Not IsNull([Subject_Name]) Or
[Subject_Name]<>"",[Subject_Name],[OldSubject_Name])

I was trying to get it to show up in the listbox in the view mode but to no
avail. Is it to do with the fact that it's not one of the fields exist in the
table?

How do i work around this?

Thank you in advance
 
Hi,

I need help with the following issue.

In the form, i have a listbox whose row source made up of two different
tables.
In one of the field i set it up as follows

Expr1: IIf(Not IsNull([Subject_Name]) Or
[Subject_Name]<>"",[Subject_Name],[OldSubject_Name])

I was trying to get it to show up in the listbox in the view mode but to no
avail. Is it to do with the fact that it's not one of the fields exist in the
table?

NULL is not unequal to "". It's not equal (or unequal) to anything!

Try

Iif(NZ([Subject_Name], "") <> "", [Subject_Name], [OldSubject_Name])

Better yet, don't use Allow Zero Length in your table unless you have one of
the VERY rare cases where you must do so, dragged kicking and screaming to
turn it on. That would let you just use NZ:

NZ([Subject_Name], [OldSubject_Name])
 
Back
Top