How to get totalExecutionTime?


I would like to realize popup which shows processing time at last step.
I know log includes totalExecutionTime, so I wonder if there are some way to get this time.
I’ve already implemented two activities to get time using CurrentDate activity, at first and last step, then calculate time difference, but it does not look smart…


Stopwatch is designed for this purpose and is one of the best way to measure time execution in .NET.
var watch = System.Diagnostics.Stopwatch.StartNew();
// the code that you want to measure comes here
var elapsedMs = watch.ElapsedMilliseconds;

for xaml.


Hi, thank you for sharing.
I think both Stopwatch and two CurrentDate do not use totalExecutionTime.
Both way can manually get almost processing time, so these are similar.
I would like to know whether I can get totalExecutionTime, because it seems standard variable.