What is wrong about the way i am using OR in this code line?

  • Thread starter Thread starter Miguel Dias Moura
  • Start date Start date
M

Miguel Dias Moura

Hi,

i want to make a table visible if any of 3 database field values are
different from "".

The code i have is this:

visible='<%# dataSetPerson.FieldValue("Value1", Container) <> "" OR
dataSetPerson.FieldValue("Value2", Container) <> "" OR
dataSetPerson.FieldValue("Value3", Container) <> "" %>'

This is not working. I am using ASP.NET / VB.

Thanks,
Miguel
 
Hi Miguel,

When I see it good, than you are using the bitwise operator which gives a
value to the html panel which is probably unpredictable.

I showed you a sample how to do it, use it or try it.
And to not mix it up you can better use OrElse

Cor
 
Back
Top