FMK
(RPA Learner .)
1
How to iterate through a column to fetch the data till a specific value appears .
for example : I would like to sum the values until the month of Feb (months are passed as argument depend on the user needs )
for now i have created a DT with all values from the excel
then tried to filter the DT but no option to specify
msan
(Michel SAN)
2
Variable (String)
Sentinel= “Feb”
Variable (Int32)
Result = 0
ForEachRow in DT:
LogMessage
Result.ToString
2 Likes
ppr
(Peter Preuss)
3
@FMK
as an alternate it can be done with using Take() and Sum()
dtData.AsEnumerable.Take(idx +1).Sum(Function (r) CInt(r(1).toString))
Find Demo XAML here
FMK.xaml (7.8 KB)
4 Likes
FMK
(RPA Learner .)
4
thank you all , both solutions worked
FMK
(RPA Learner .)
5
I also have a question how can i get the values of the monthes after Feb till current month
for example i need each value of March and April
ppr
(Peter Preuss)
7
@FMK
Find a starter help here:
FMK2.xaml (9.8 KB)
1 Like
system
(system)
Closed
9
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.