How to check "ToLower" while comparing this datatabl

Hi team,

while writing -

vDTCheatSheet.Asenumerable.Where(Function(r) r(“Supplier Name”).Tostring.Trim.equals(InArgSupplierName.Trim)).Copytodatatable

I want to convert to lowercase and check but I am not able to convert it for r(“SupplierName”).ToString

Can you let me know how to do it?

Regards,
G

Hi @gokul1904 ,

Could you just append .ToLower to the above and check ?

We also would mention that when checking case insensitive, we would convert both operands to the same case, In your case, InArgSupplierName.Trim.ToLower would also be required, For a case sensitive operation, we could keep the words/strings as it is.

1 Like

@gokul1904

You are almost there just append .ToLower Use this expression

vDTCheatSheet.Asenumerable.Where(Function(r) r(“Supplier Name”).Tostring.Trim.ToLower.equals(InArgSupplierName.Trim)).Copytodatatable

Regards
Sudharsan

Hello @gokul1904

Please check the below post.

r(“SupplierName”).ToString.ToLower

Thanks

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.