If statement just go to "else"

Hello,

I have a issue in a “invoke workflow” activity. At a certain point i have to compare a variable (filename) taken from the main process and compare it with a file name in another variable in a “invoke workflow”.

The If statement always goes to “else”, I know that this is wrong and that “then” should be the correct answer several times.

Could anyone help me troubleshoot this?

Try printing both the values and check whether they are exactly same or not!

1 Like

Thanks! I had to make a smaller number of files to check first since the folder contains above 90 000.

I see that one of the values ends on .XML and the other on .xml.

Will UiPath be able to see the difference between capital letters and small letters? or could this be the issue?

Hi! When comparing you can use YourVariable.Tolower
This will convert your string to lower case!

This solved the problem :smiley: Thanks!

1 Like