Hello all,
I want to have an if condition which checks if the current row of a specific column is empty.
I have tried it with: CurrentRow(“ColumnName”)=Nothing
and
CurrentRow(“ColumnName”)=“”
But it wont work.
Any other ideas?
Hello all,
I want to have an if condition which checks if the current row of a specific column is empty.
I have tried it with: CurrentRow(“ColumnName”)=Nothing
and
CurrentRow(“ColumnName”)=“”
But it wont work.
Any other ideas?
@VLC,
Use this expression to check if the field is empty or not
Convert.IsDBNull(CurrentRow(“ColumnName”)) OrElse String.IsNullOrEmpty(CurrentRow(“ColumnName”).ToString)
If this return true, it means the field is empty.
multiple ways and using trim might help in few cases
currentRow("ColumnName") Is Nothing OrElse currentRow("ColumnName").ToString Is DBNull.Value OrElse String.IsNullOrEmpty(currentRow("ColumnName")>ToString.Trim)
cheers
Hi @VLC
Use this condition:
String.IsNullOrWhiteSpace(CurrentRow(“ColumnName”).ToString)
It’ll check for both Nothing and empty values.
If you found helpful please mark as a solution. Thanks
Happy Automation with UiPath
Most likely the issue was with my write cell activity where I gave a wrong index so not all empty cell where filled but some which where not empty where filled. But I think all your solutions work
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.