When we use And, Andalso, or, orelse

HI,

How about the following? This sample assumes “Name” always exists (excluded from the evaluation)

data only have email,

Not String.IsNullOrEmpty(row("Email").ToString) AndAlso String.IsNullOrEmpty(row("Phone").ToString) AndAlso String.IsNullOrEmpty(row("Title").ToString)

data have no email and phone but have title

String.IsNullOrEmpty(row("Email").ToString) AndAlso String.IsNullOrEmpty(row("Phone").ToString) AndAlso (not String.IsNullOrEmpty(row("Title").ToString))

Sample20221125-4.zip (4.7 KB)

Regards,