Using if Statement to find something in Excel

Hello, I’m trying to check in the Excel file if there is someone named Jane in “First Name” so I can use it for Business Exception. I’ve been trying to do it like “in_TransactionItem(“First Name” = John)” but turns out it doesn’t work like that. How can I do this? Thanks

Hope in_Transactionitem is ur table name.
Bracket needs to be closed after First Name
In_Transactionitem(“First Name”).toString.Trim=“John” try this

Hey @Otto_Kampas

Please confirm what is the type of your variable in_TransactionItem

Thanks
#nK

Hi @Otto_Kampas,

in_TransactionItem if this variable is a queue item;

in_TransactionItem.SpecificContent(“First Name”).ToString.Trim = “John”

if it is a datarow

in_TransactionItem.(“First Name”).ToString.Trim = “John”

you should use.

Regards,
MY

Hello @Otto_Kampas

The formula is totally depends on your requirement.

if you want to check whethe the datatable contains the particular string in that column you can do as below.

yourDT.AsEnumerable().Any(Function(x) x(“Column1”).ToString = DesiredValue)