Regarding Excel activity

Hi All, Needed your help

In the attached excel I want to perform large operation on each row having error(column)>0 and with Receiver Component(column)> ASN. Sometimes it’s only 1 but sometimes it’s more than 1. But for more than one there are few activities extra that’s needed to be added and also I want to stop the loop once it’s done.
If anybody can help me in putting the logic

image

Little more explanation:
if ( rows having (error >0 and component = ASN) >1)
{
has some extra activities
basic workflow
}
else ( rows having (error >0 and component = ASN) =1)
{
basic workflow
}

Do you want to keep only the columns that have a error value > 0 and the receiver column contains ASN?

Hey @anjasing,

Use the for each row activity and inside for each use the below if conditon.

Cint(row(“Error”).tostring.trim) >0 and row(“Component”).tostring.Trim.Contains(“ASN”)

1 Like

@anjasing,

What exactly do you need? Filtering to get a datatable of rows you want?

yes exactly

Hi @shreyash_shirbhate could u plz read the query again and answer…that would be really helpful

image
Try using the Filter Data Table activity and use these values… or depending on how you want it. Should work.
Thanks.

Hi @_arbso I want to do below mentioned process basically:
if ( rows having (error >0 and component = ASN) >1)
{
has some extra activities
basic workflow
}
else ( rows having (error >0 and component = ASN) =1)
{
basic workflow
}

Actually I want to put the condition in if loop don’t want to operate on datatable

You can try going through each row of the datatable with the for each row in data table activity and putting an IF activity with the condition for example:

CurrentRow(“Error”) > 0 AND CurrentRow(“Receiver Partner”).Contains(“ASN”)
// workflow
else
(your other condition)
// workflow