How to know a compare the value of a row's first cell in excel in uipath

Hi, I have an excel sheet with 2 columns with headers of “key”, “value”. I want to check for each condition that a certain value exists in “key” of a row, then assign a variable to the “value” of that row.

for example, if a cell value “from” exists in the “key” of a row, I must assign a variable to the corresponding “value” cell. please help me out.

can you please explain bit more clear @Srikavya_n


  1. Use Read Range activity to read the data from excel file and will give you output as DataTable and say ‘DT’. And then use ForEach Row activity to iterate that DataTable.

    ForEach row in DT
    IF row(“Key”).Tostring.Length > 0
    Then row(“Value”) = “value”
    Else Nothing

Finally use Write Range activity to write into Excel file.

i want to check if a row’s first key under header - key value.
for example

dataRow[Key].toString == “from” , then assifn variable to its corresponding cell in value i.e., “” into a variable

getting confused at specifying the condition at if condition


In IF condition, specify single = instead of double equal.

use single = for checking the condition.