Hello Folks,
i want to assign no of cells that exist in last row only (highlighted in green to one variable ) to use it in a for each loop later , any advice ?
i want to assign no of cells that exist in last row only (highlighted in green to one variable ) to use it in a for each loop later , any advice ?
Can you elaborate?
Like are you trying to find the number of Non-Empty cells in last row?
i want to create variable x ={supplier email1 ,supplier email2 , supplier email3 } as strings to use it in for each loop
hey @sesa499170 ,
can you tel me headers of these required column ? so that i can use LINQ
regards,
Dheerendra Vishwakarma
hi @sesa499170 ,
You can do something like this:
Hope this helps
hello @sesa499170 ,
you can achieve your goal using 2 assign activity i have used LINQ for faster processing and efficiency.
As you can see
in first assign i have extracted required columns as store it in datatable variable and in second assign acivity i have extracted last row and storing it in out_VAR(Array of string type)
first assign replace the headers
n_DT.AsDataView.ToTable(False,{"Header of Suplier email1" ,"Header of Suplier email2","Header of Suplier email3"})
and second assign extracting last row and storing it in array of string variable
Required_DT.AsEnumerable().Last().ItemArray.Select(Function(x) x.ToString).ToArray()
after this you can use for each activity and pass above output variable(out_VAR) to see the result.
i am attaching .xmal file for your refence just replace the headers in first assign you will get your result easily
new_mode(Autosaved).xaml (9.3 KB)
hope it will help you
Regards,
Dheerendra Vishwakarma
take assign activity LastIndex = Table.RowCount-1
then take second assign activity Array = {Table(LastIndex)(coulumnIndex),Table(LastIndex)(1),Table(LastIndex)(2)}
@sesa499170 if you got the answer please don’t forget to mark it as answer so that this topic can be closed
Happy Automation!!
Thanks A lot , it works , many thanks for all of you
, great help
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.