Please use filter datatable with the column name and the variable as the value
and then use a if condition to check the count dt.rowcount>0
or use linq
dt.AsEnumerable.Where(function(x) x("Columnname").ToString.Contains(Variablename)).Count>0
Please mark the solution if resolved else happy to help
cheers