nithya
June 18, 2024, 3:22pm
1
Hi Everyone,
If Data table column (“Account Number”) is any one the number mentioned below, then bot needs to update (“Category”) Column as " Success"
Note – The new account number may be added based on business needs.
30653
33819
38474
47008
Kindly, help me on providing solution to this scenario.
Thanks
postwick
(Paul Ostwick)
June 18, 2024, 3:24pm
2
A simple For Each Row in Data Table will do it.
For Each Row in Data Table
– If {“30653”,“33819”,“38474”,“47008”}.Contains CurrentRow(“Account Number”).ToString
— Assign CurrentRow(“Category”) = “Success”
vrdabberu
(Varunraj Dabberu)
June 18, 2024, 3:31pm
3
Hi @nithya
=> Read Range Workbook
Output → dt
=> Use below syntax in Assign:
accountNumbers = New List(Of String)() From {"30653", "33819", "38474", "47008"}
accountNumbers
is of DataType System.Collections.Generic.List(System.String)
=> Use below code in Invoke Code:
yourDataTable.AsEnumerable().ToList().ForEach(Sub(row) If accountNumbers.Contains(row("Account Number").ToString()) Then row("Category") = "Success")
Invoke Arguments:
=> Write Range Workbook dt
back to excel.
FLOW:
XAML:
Sequence88.xaml (8.8 KB)
Regards