Please help! It is very important.
I vave Dt. If in cell in last row in first column empty - I need filter me DT(delete last row)
If not empty -not change
you need to get last row value in firstcolumn?
Hi @RPA3
Hi Just count the Datatable and issue the command Deleterows activities and pass the count of the datatable for you to check the last row.
cheers
Happy learning
@RPA3 in if Activity use DT(DT.Rows.Count-1)(0).toString.isNullOrWhitspace , If True Filter the DT, Else Leave it Empty , I guess this is What you needed
hi @supermanPunch
( readedValue.Rows.IndexOf( readedValue.AsEnumerable.Where(Function(r) r(“ColumnName”).ToString.Trim <> “”).ToArray.Last ) + 2 ) this function retrieve the number of rows from your column, just check if the last row have any value or not.
Regards!
yes, it true
It is not work for me:(
@RPA3 Did you get any Error?
lastValueinRow.xaml (7.5 KB)
cheers @RPA3
@RPA3 it is DT(DT.Rows.Count-1)(0).toString
wow, it is great :смеющийся:
But DT(DT.Rows.Count-1)(0).ToString.isNullOrWhitspace
isNullOrWhitspace - not work
@RPA3 try this DT(DT.Rows.Count-1)(0).toString.isNullOrEmpty
@RPA3 Check this String.IsNullOrEmpty(DT(DT.Rows.Count-1)(0).toString)
same error
I use this to read the column i want with the Read Range Activity.
You wanted to print it in write line, but it gives you boolean value. So u need to put in write line with value:
(String.IsNullOrEmpty(DT(DT.Rows.Count-1)(0).toString)).toString
Then u should get true/false
And when u get it u can just put if to the workflow with:
String.IsNullOrEmpty(DT(DT.Rows.Count-1)(0).toString)
and in yes path just put remove data row with this dt in the value and rowindex= DT.Rows.Count-1