-
Notifications
You must be signed in to change notification settings - Fork 67
/
Copy pathMain.xaml
1496 lines (1496 loc) · 113 KB
/
Main.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<Activity mc:Ignorable="sap sap2010 sads" x:Class="Main"
xmlns="http://schemas.microsoft.com/netfx/2009/xaml/activities"
xmlns:av="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:mva="clr-namespace:Microsoft.VisualBasic.Activities;assembly=System.Activities"
xmlns:s="clr-namespace:System;assembly=mscorlib"
xmlns:sads="http://schemas.microsoft.com/netfx/2010/xaml/activities/debugger"
xmlns:sap="http://schemas.microsoft.com/netfx/2009/xaml/activities/presentation"
xmlns:sap2010="http://schemas.microsoft.com/netfx/2010/xaml/activities/presentation"
xmlns:scg="clr-namespace:System.Collections.Generic;assembly=mscorlib"
xmlns:sco="clr-namespace:System.Collections.ObjectModel;assembly=mscorlib"
xmlns:sd="clr-namespace:System.Data;assembly=System.Data"
xmlns:ui="http://schemas.uipath.com/workflow/activities"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<x:Members>
<x:Property Name="OrchestratorQueueName" Type="InArgument(x:String)" />
</x:Members>
<mva:VisualBasic.Settings>
<x:Null />
</mva:VisualBasic.Settings>
<sap2010:WorkflowViewState.IdRef>Main2_1</sap2010:WorkflowViewState.IdRef>
<TextExpression.NamespacesForImplementation>
<sco:Collection x:TypeArguments="x:String">
<x:String>System.Activities</x:String>
<x:String>System.Activities.Statements</x:String>
<x:String>System.Activities.Expressions</x:String>
<x:String>System.Activities.Validation</x:String>
<x:String>System.Activities.XamlIntegration</x:String>
<x:String>Microsoft.VisualBasic</x:String>
<x:String>Microsoft.VisualBasic.Activities</x:String>
<x:String>System</x:String>
<x:String>System.Collections</x:String>
<x:String>System.Collections.Generic</x:String>
<x:String>System.Data</x:String>
<x:String>System.Diagnostics</x:String>
<x:String>System.Drawing</x:String>
<x:String>System.IO</x:String>
<x:String>System.Linq</x:String>
<x:String>System.Net.Mail</x:String>
<x:String>System.Xml</x:String>
<x:String>System.Xml.Linq</x:String>
<x:String>UiPath.Core</x:String>
<x:String>UiPath.Core.Activities</x:String>
<x:String>System.Windows.Markup</x:String>
<x:String>System.Xml.Serialization</x:String>
<x:String>Newtonsoft.Json.Linq</x:String>
<x:String>Newtonsoft.Json</x:String>
<x:String>Microsoft.VisualBasic.CompilerServices</x:String>
<x:String>System.Net</x:String>
</sco:Collection>
</TextExpression.NamespacesForImplementation>
<TextExpression.ReferencesForImplementation>
<sco:Collection x:TypeArguments="AssemblyReference">
<AssemblyReference>System.Activities</AssemblyReference>
<AssemblyReference>Microsoft.VisualBasic</AssemblyReference>
<AssemblyReference>mscorlib</AssemblyReference>
<AssemblyReference>System.Data</AssemblyReference>
<AssemblyReference>System</AssemblyReference>
<AssemblyReference>System.Drawing</AssemblyReference>
<AssemblyReference>System.Core</AssemblyReference>
<AssemblyReference>System.Xml</AssemblyReference>
<AssemblyReference>System.Xml.Linq</AssemblyReference>
<AssemblyReference>UiPath.Core</AssemblyReference>
<AssemblyReference>UiPath.Core.Activities</AssemblyReference>
<AssemblyReference>PresentationFramework</AssemblyReference>
<AssemblyReference>WindowsBase</AssemblyReference>
<AssemblyReference>PresentationCore</AssemblyReference>
<AssemblyReference>System.Xaml</AssemblyReference>
<AssemblyReference>System.ComponentModel.Composition</AssemblyReference>
<AssemblyReference>System.ServiceModel</AssemblyReference>
<AssemblyReference>Microsoft.VisualStudio.Services.Common</AssemblyReference>
<AssemblyReference>System.Data.DataSetExtensions</AssemblyReference>
<AssemblyReference>System.Runtime.WindowsRuntime</AssemblyReference>
<AssemblyReference>Newtonsoft.Json</AssemblyReference>
<AssemblyReference>System.Collections.Immutable</AssemblyReference>
</sco:Collection>
</TextExpression.ReferencesForImplementation>
<TryCatch sap2010:Annotation.AnnotationText="This is a template for running production-ready process models. This is the main workblock and entry point of the program." DisplayName="workblock main.xaml" sap2010:WorkflowViewState.IdRef="TryCatch_43">
<TryCatch.Variables>
<Variable x:TypeArguments="x:String" Name="wbPath" />
<Variable x:TypeArguments="x:String" Name="wbName" />
<Variable x:TypeArguments="s:DateTime" Name="wbStartTime" />
</TryCatch.Variables>
<TryCatch.Try>
<Sequence DisplayName="Try processing wb" sap2010:WorkflowViewState.IdRef="Sequence_391">
<Sequence sap2010:Annotation.AnnotationText="During block startup, information about the path are constructed. It will be passed to any child workblock.
You should also publish the input arguments that you want to make available in the log" DisplayName="wbStartup" sap2010:WorkflowViewState.IdRef="Sequence_408">
<Assign sap2010:Annotation.AnnotationText="Edit to assign a name of your choosing" DisplayName="Assign workblock its name" sap2010:WorkflowViewState.IdRef="Assign_225">
<Assign.To>
<OutArgument x:TypeArguments="x:String">[wbName]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:String">Main</InArgument>
</Assign.Value>
</Assign>
<Assign sap2010:Annotation.AnnotationText="Create current workblock path. This will be passed to children wb, if any" DisplayName="Create workblock path" sap2010:WorkflowViewState.IdRef="Assign_226">
<Assign.To>
<OutArgument x:TypeArguments="x:String">[wbPath]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:String">[wbName]</InArgument>
</Assign.Value>
</Assign>
<Assign sap2010:Annotation.AnnotationText="Assign template start time. " DisplayName="Assign start time" sap2010:WorkflowViewState.IdRef="Assign_11">
<Assign.To>
<OutArgument x:TypeArguments="s:DateTime">[wbStartTime]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="s:DateTime">[datetime.Now]</InArgument>
</Assign.Value>
</Assign>
<ui:AddLogFields sap2010:Annotation.AnnotationText="Default wb fields
wbName
wbParentName
wbKey
wbPath
wbLevel
wbStartTime
wbState" DisplayName="Publish default wb fields" sap2010:WorkflowViewState.IdRef="AddLogFields_102">
<ui:AddLogFields.Fields>
<InArgument x:TypeArguments="x:String" x:Key="wbName">[wbName]</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbParentName">[if(wbPath.Count(Function(x) x="|") = 0, string.Empty, wbPath.Split("|".ToCharArray)(wbPath.Count(Function(x) x="|")-1))]</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbKey">[Guid.NewGuid.ToString]</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbPath">[wbPath]</InArgument>
<InArgument x:TypeArguments="x:Int32" x:Key="wbLevel">[wbPath.Count(Function(x) x="|")]</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbState">Executing</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbStartTime">[wbStartTime.ToString("yyyyMMdd HH:mm:ss.fff")]</InArgument>
</ui:AddLogFields.Fields>
</ui:AddLogFields>
<ui:AddLogFields sap2010:Annotation.AnnotationText="Publish input fields
businessProcessName" DisplayName="Add log fields" sap2010:WorkflowViewState.IdRef="AddLogFields_108">
<ui:AddLogFields.Fields>
<InArgument x:TypeArguments="x:String" x:Key="businessProcessName">UiPath_Enhanced_ReFramework</InArgument>
</ui:AddLogFields.Fields>
</ui:AddLogFields>
<ui:LogMessage DisplayName="Log execution started message" sap2010:WorkflowViewState.IdRef="LogMessage_41" Level="Info" Message="[wbPath + " execution started."]" />
</Sequence>
<StateMachine sap2010:Annotation.AnnotationText="This is a template for running production-ready process models. This is the main entry point of the program.
You are receiving a pre-configuered state machine that implements retry-able components with interfaces built-in for the user to write his own business logic. 
You can begin work right away by editing the business layer components found in the ProcessLayer folder. 
To learn more about how all of this works, read the documents included in the Documentation Folder. " DisplayName="ReFramework - Transactional business process engine" sap2010:WorkflowViewState.IdRef="StateMachine_2">
<StateMachine.InitialState>
<State x:Name="__ReferenceID2" sap2010:Annotation.AnnotationText="##Framework Layer##
Read Config. Initialize all applications. Recover the environment from System Error by Closing and Initializing all applications." DisplayName="Init State" sap2010:WorkflowViewState.IdRef="State_8">
<State.Entry>
<TryCatch sap2010:Annotation.AnnotationText="Initialization state guard" DisplayName="Init" sap2010:WorkflowViewState.IdRef="TryCatch_33">
<TryCatch.Try>
<Sequence DisplayName="Try processing Init" sap2010:WorkflowViewState.IdRef="Sequence_346">
<Sequence sap2010:Annotation.AnnotationText="This section is needed for the correct operation of the framework. Edits here break things." DisplayName="System - Reserved" sap2010:WorkflowViewState.IdRef="Sequence_343">
<If Condition="[Config is Nothing]" DisplayName="If first run - read Config file" sap2010:WorkflowViewState.IdRef="If_73">
<If.Then>
<Sequence DisplayName="First Run" sap2010:WorkflowViewState.IdRef="Sequence_341">
<ui:LogMessage DisplayName="Log message" sap2010:WorkflowViewState.IdRef="LogMessage_44" Level="Info" Message="Initialising Settings" />
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke InitAllSettings workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_118" UnSafe="False" WorkflowFileName="Framework\InitAllSettings.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="x:String" x:Key="in_ConfigFile">Data\Config.xlsx</InArgument>
<InArgument x:TypeArguments="s:String[]" x:Key="in_ConfigSheets">[{"Settings", "Credentials", "Tasks", "Constants"}]</InArgument>
<OutArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="out_Config">[Config]</OutArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
<Sequence sap2010:Annotation.AnnotationText="Save job arguments with values to Config, using the argument's name as keyname. " DisplayName="Save job arguments Config" sap2010:WorkflowViewState.IdRef="Sequence_415">
<If Condition="[Not string.IsNullOrEmpty(OrchestratorQueueName)]" DisplayName="OrchestratorQueueName" sap2010:WorkflowViewState.IdRef="If_100">
<If.Then>
<Assign DisplayName="Add OrchestratorQueueName" sap2010:WorkflowViewState.IdRef="Assign_227">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[Config("OrchestratorQueueName")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[OrchestratorQueueName]</InArgument>
</Assign.Value>
</Assign>
</If.Then>
<If.Else>
<ui:Comment sap2010:WorkflowViewState.IdRef="Comment_1" Text="// If the argument has no value, do not overwrite config. This provides backward compatibility with < 2018.3 and allows default values to come from the Config.xlsx" />
</If.Else>
</If>
</Sequence>
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke CleanupAndPrep workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_148" UnSafe="False" WorkflowFileName="ProcessLayer\CleanupAndPrep.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="in_Config">[Config]</InArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</Sequence>
</If.Then>
</If>
<If Condition="[cint(SystemReserved.Item("TransactionNumber"))=1 AND CInt(SystemReserved.Item("RetryNumber")) = 0 AND CInt(SystemReserved.Item("InitRetryNumber"))=0 AND cint(Config.Item("SystemTask1_Enable"))=1]" DisplayName="If service is not enabled do not run" sap2010:WorkflowViewState.IdRef="If_74">
<If.Then>
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" sap2010:Annotation.AnnotationText="Run This only once, after reading local settings and cleaning up the environment" DisplayName="Invoke FirstRunMain workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_120" UnSafe="False" WorkflowFileName="ServicesLayer\FirstRun\Main.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="x:String" x:Key="in_wbParentPath">[wbPath]</InArgument>
<InOutArgument x:TypeArguments="scg:List(sd:DataRow)" x:Key="io_TransactionData" />
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</If.Then>
</If>
<Sequence DisplayName="Reset Env in case of SystemError" sap2010:WorkflowViewState.IdRef="Sequence_342">
<If Condition="[SystemError isNot Nothing]" DisplayName="If System Error Reset Env" sap2010:WorkflowViewState.IdRef="If_75">
<If.Then>
<Sequence DisplayName="Reset Env" sap2010:WorkflowViewState.IdRef="Sequence_414">
<ui:LogMessage DisplayName="Log message" sap2010:WorkflowViewState.IdRef="LogMessage_46" Level="Info" Message="Resseting application environment" />
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke CloseAllApplications workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_121" UnSafe="False" WorkflowFileName="ProcessLayer\CloseAllApplications.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="in_Config">[Config]</InArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</Sequence>
</If.Then>
</If>
<Assign DisplayName="Initialize SystemError" sap2010:WorkflowViewState.IdRef="Assign_186">
<Assign.To>
<OutArgument x:TypeArguments="s:Exception">[SystemError]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="s:Exception">[Nothing]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</Sequence>
<Sequence sap2010:Annotation.AnnotationText="Call Business Process Layer" DisplayName="Business Process Layer Interface" sap2010:WorkflowViewState.IdRef="Sequence_344">
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke InitiAllApplications workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_122" UnSafe="False" WorkflowFileName="ProcessLayer\InitAllApplications.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="in_Config">[Config]</InArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</Sequence>
</Sequence>
</TryCatch.Try>
<TryCatch.Catches>
<Catch x:TypeArguments="s:Exception" sap2010:WorkflowViewState.IdRef="Catch`1_46">
<ActivityAction x:TypeArguments="s:Exception">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="s:Exception" Name="exception" />
</ActivityAction.Argument>
<Sequence sap2010:Annotation.AnnotationText="Get Exception Information Here. Although you can set an optional Status here, it is recommended you do it in your own try-catch block." DisplayName="Collect and output the exception" sap2010:WorkflowViewState.IdRef="Sequence_399">
<Assign DisplayName="Assign exception to SystemError" sap2010:WorkflowViewState.IdRef="Assign_219">
<Assign.To>
<OutArgument x:TypeArguments="s:Exception">[SystemError]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="s:Exception">[exception]</InArgument>
</Assign.Value>
</Assign>
<ui:LogMessage DisplayName="Log exception message" sap2010:WorkflowViewState.IdRef="LogMessage_47" Level="Error" Message="["An exception has occurred: " + exception.Message + " at Source: " + exception.Source]" />
</Sequence>
</ActivityAction>
</Catch>
</TryCatch.Catches>
</TryCatch>
</State.Entry>
<State.Transitions>
<Transition DisplayName="Success" sap2010:WorkflowViewState.IdRef="Transition_20">
<Transition.To>
<State x:Name="__ReferenceID0" sap2010:Annotation.AnnotationText="##Framework Layer##
Retrieve, set and maintain transactional business data. Decide when process ends by setting TransactionItem to Nothing.

" DisplayName="Get/Set Transaction Data State" sap2010:WorkflowViewState.IdRef="State_7">
<State.Entry>
<TryCatch sap2010:Annotation.AnnotationText="GetSetTransactionData state guard" DisplayName="GetSetTransactionData" sap2010:WorkflowViewState.IdRef="TryCatch_34">
<TryCatch.Try>
<Sequence DisplayName="Try processing GetSetTransactionData" sap2010:WorkflowViewState.IdRef="Sequence_357">
<Sequence.Variables>
<Variable x:TypeArguments="x:Boolean" Name="ShouldStop" />
</Sequence.Variables>
<Sequence sap2010:Annotation.AnnotationText="This section is needed for the correct operation of the framework. Edits here break things." DisplayName="System - Reserved" sap2010:WorkflowViewState.IdRef="Sequence_353">
<Assign DisplayName="Delete BusinessRuleException" sap2010:WorkflowViewState.IdRef="Assign_192">
<Assign.To>
<OutArgument x:TypeArguments="s:Exception">[SystemError]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="s:Exception">[Nothing]</InArgument>
</Assign.Value>
</Assign>
<ui:ShouldStop DisplayName="Check Stop Signal" sap2010:WorkflowViewState.IdRef="ShouldStop_7" Result="[ShouldStop]" />
<If Condition="[ShouldStop]" DisplayName="If stop requested" sap2010:WorkflowViewState.IdRef="If_77">
<If.Then>
<Sequence DisplayName="Orchestrator stop" sap2010:WorkflowViewState.IdRef="Sequence_352">
<Sequence DisplayName="Logging and cleanup" sap2010:WorkflowViewState.IdRef="Sequence_351">
<Assign DisplayName="End Process" sap2010:WorkflowViewState.IdRef="Assign_193">
<Assign.To>
<OutArgument x:TypeArguments="ui:QueueItem">[TransactionItem]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="ui:QueueItem">[Nothing]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</Sequence>
</If.Then>
</If>
</Sequence>
<Sequence sap2010:Annotation.AnnotationText="Call Data Layer" DisplayName="Data Layer Interface" sap2010:WorkflowViewState.IdRef="Sequence_355">
<If Condition="[not(ShouldStop)]" DisplayName="If we should not stop, get next transaction Data" sap2010:WorkflowViewState.IdRef="If_79">
<If.Then>
<Sequence DisplayName="Call GetData Service and GetData" sap2010:WorkflowViewState.IdRef="Sequence_354">
<If sap2010:Annotation.AnnotationText="Set the flag that will run The GetData service if you need to get data from an Application, website or Resource that might fail. Use the Config and Not this flag enable or disable it." Condition="[(cint(Config.Item("SystemTask2_Enable"))=1 AND (cint(SystemReserved.Item("TransactionNumber")) = 1 and cint(SystemReserved.Item("RetryNumber")) = 0)) OR (cint(Config.Item("SystemTask2_Enable"))=2)]" DisplayName="Configure the run Condition of this Service in Config.xlsx" sap2010:WorkflowViewState.IdRef="If_78">
<If.Then>
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" sap2010:Annotation.AnnotationText="Make sure to pass io_Transaction data if you need the service to fetch data for you." DisplayName="Invoke GetData Main workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_125" UnSafe="False" WorkflowFileName="ServicesLayer\GetData\Main.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="x:String" x:Key="in_wbParentPath">[wbPath]</InArgument>
<OutArgument x:TypeArguments="scg:List(sd:DataRow)" x:Key="out_TransactionData">[TransactionData]</OutArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</If.Then>
</If>
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" sap2010:Annotation.AnnotationText="Use this To get local data and to assign TransactionItem" DisplayName="Invoke GetSetTransactionData workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_126" UnSafe="False" WorkflowFileName="ProcessLayer\GetSetTransactionData.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="x:String" x:Key="in_wbParentPath">[wbPath]</InArgument>
<InArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="in_Config">[Config]</InArgument>
<InOutArgument x:TypeArguments="ui:QueueItem" x:Key="io_TransactionItem">[TransactionItem]</InOutArgument>
<InOutArgument x:TypeArguments="scg:List(sd:DataRow)" x:Key="io_TransactionData">[TransactionData]</InOutArgument>
<InArgument x:TypeArguments="x:Int32" x:Key="in_TransactionNumber">[cint(SystemReserved.Item("TransactionNumber"))]</InArgument>
<InArgument x:TypeArguments="x:Int32" x:Key="in_RetryNumber">[cint(SystemReserved.Item("RetryNumber"))]</InArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</Sequence>
</If.Then>
</If>
</Sequence>
</Sequence>
</TryCatch.Try>
<TryCatch.Catches>
<Catch x:TypeArguments="s:Exception" sap2010:WorkflowViewState.IdRef="Catch`1_47">
<ActivityAction x:TypeArguments="s:Exception">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="s:Exception" Name="exception" />
</ActivityAction.Argument>
<Sequence sap2010:Annotation.AnnotationText="Get Exception Information Here. Although you can set an optional Status here, it is recommended you do it in your own try-catch block." DisplayName="Collect and output the exception" sap2010:WorkflowViewState.IdRef="Sequence_398">
<Assign DisplayName="Assign exception to SystemError" sap2010:WorkflowViewState.IdRef="Assign_218">
<Assign.To>
<OutArgument x:TypeArguments="s:Exception">[SystemError]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="s:Exception">[exception]</InArgument>
</Assign.Value>
</Assign>
<ui:LogMessage DisplayName="Log exception message" sap2010:WorkflowViewState.IdRef="LogMessage_50" Level="Error" Message="["An exception has occurred: " + exception.Message + " at Source: " + exception.Source]" />
</Sequence>
</ActivityAction>
</Catch>
</TryCatch.Catches>
</TryCatch>
</State.Entry>
<State.Transitions>
<Transition sap2010:Annotation.AnnotationText="This is a simple mecanism to stop the process.
In reallife scenario you can stop the process when there is no more data to process or on a schedule." DisplayName="No Data" sap2010:WorkflowViewState.IdRef="Transition_13" Condition="[TransactionItem Is Nothing And SystemError is Nothing]">
<Transition.To>
<State x:Name="__ReferenceID1" sap2010:Annotation.AnnotationText="##Framework Layer##
Process stops here as a result of no more data(TransactionItem is Nothing), an exception in the Data Layer, successive exceptions in the Init state, consecutive exceptions in the Process state." DisplayName="End Process State" sap2010:WorkflowViewState.IdRef="State_5" IsFinal="True">
<State.Entry>
<Sequence sap2010:Annotation.AnnotationText="End Process State" DisplayName="End Process" sap2010:WorkflowViewState.IdRef="Sequence_405">
<Sequence sap2010:Annotation.AnnotationText="This section is needed for the correct operation of the framework. Edits here break things." DisplayName="System - reserved" sap2010:WorkflowViewState.IdRef="Sequence_401" />
<Sequence sap2010:Annotation.AnnotationText="Call Business Process Layer" DisplayName="Business Process Layer Interface" sap2010:WorkflowViewState.IdRef="Sequence_403">
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke CloseAllApplications workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_146" UnSafe="False" WorkflowFileName="ProcessLayer\CloseAllApplications.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="in_Config">[Config]</InArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
<Sequence sap2010:Annotation.AnnotationText="Under a set of conditions, we wish to abort the applications and not consume the exception. This will register as a failed job in Orchestrator, and we can send a notification email" DisplayName="Abort Application conditions" sap2010:WorkflowViewState.IdRef="Sequence_402">
<If Condition="[SystemReserved.Item("RobotFail").ToString = "Init"]" DisplayName="If we are here due to an SystemError in Init State" sap2010:WorkflowViewState.IdRef="If_97">
<If.Then>
<Throw sap2010:Annotation.AnnotationText="Throw System Exception.
The Process has Failed to Initialize" DisplayName="Throw SYS Exception" Exception="[new system.exception("The Process has Failed to Initialize.",SystemError)]" sap2010:WorkflowViewState.IdRef="Throw_10" />
</If.Then>
</If>
<If Condition="[SystemReserved.Item("RobotFail").ToString = "GetSetData"]" DisplayName="If we are here due to an SystemError in GetSetTransactionData State" sap2010:WorkflowViewState.IdRef="If_98">
<If.Then>
<Throw sap2010:Annotation.AnnotationText="Throw System Exception.
The Process has Failed to Get/Set Data" DisplayName="Throw SYS Exception" Exception="[New system.exception("The Process has Failed to Retrieve or Set Data.", SystemError)]" sap2010:WorkflowViewState.IdRef="Throw_11" />
</If.Then>
</If>
<If Condition="[SystemReserved.Item("RobotFail").ToString = "Process"]" DisplayName="If we are here due to too many consecutive SystemErrors in ProcessTransaction State" sap2010:WorkflowViewState.IdRef="If_99">
<If.Then>
<Throw sap2010:Annotation.AnnotationText="Throw System Exception.
The Process has Failed in the Process State for a consecutive number of times equal to MaxContinuousRetryNumber" DisplayName="Throw SYS Exception" Exception="[new system.exception("The Process has Failed in the Process State for a consecutive number of times equal to "+SystemReserved.Item("ContinuousRetryNumber").ToString, SystemError)]" sap2010:WorkflowViewState.IdRef="Throw_12" />
</If.Then>
</If>
</Sequence>
</Sequence>
</Sequence>
</State.Entry>
</State>
</Transition.To>
</Transition>
<Transition DisplayName="New Transaction" sap2010:WorkflowViewState.IdRef="Transition_18" Condition="[TransactionItem IsNot Nothing and SystemError Is Nothing]">
<Transition.To>
<State x:Name="__ReferenceID3" sap2010:Annotation.AnnotationText="##Framework Layer##
Interact with applications opened in Init state using data obtained in the Data Layer. A transaction that fails with a BusinessRuleException will not be retried. All others exceptions will be." DisplayName="Process Transaction State" sap2010:WorkflowViewState.IdRef="State_6">
<State.Entry>
<TryCatch sap2010:Annotation.AnnotationText="ProcessTransaction state guard" DisplayName="ProcessTransaction" sap2010:WorkflowViewState.IdRef="TryCatch_40">
<TryCatch.Try>
<Sequence DisplayName="Try processing ProcessTransaction" sap2010:WorkflowViewState.IdRef="Sequence_377">
<Sequence sap2010:Annotation.AnnotationText="This section is needed for the correct operation of the framework. Edits here break things." DisplayName="System - reserved" sap2010:WorkflowViewState.IdRef="Sequence_374" />
<Sequence sap2010:Annotation.AnnotationText="Call Business Process Layer" DisplayName="Business Process Layer Interface" sap2010:WorkflowViewState.IdRef="Sequence_375">
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke GetQueueMaxRetries workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_134" UnSafe="False" WorkflowFileName="Framework\GetQueueMaxRetries.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="ui:QueueItem" x:Key="in_TransactionItem">[TransactionItem]</InArgument>
<InOutArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="io_SystemReserved">[SystemReserved]</InOutArgument>
<InOutArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="io_Config">[Config]</InOutArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke ProcessTransaction workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_135" UnSafe="False" WorkflowFileName="ProcessLayer\ProcessTransaction.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="x:String" x:Key="in_wbParentPath">[wbPath]</InArgument>
<InArgument x:TypeArguments="scg:Dictionary(x:String, x:Object)" x:Key="in_Config">[Config]</InArgument>
<InOutArgument x:TypeArguments="ui:QueueItem" x:Key="io_TransactionItem">[TransactionItem]</InOutArgument>
<InArgument x:TypeArguments="x:Int32" x:Key="in_TransactionNumber">[cint(SystemReserved.Item("TransactionNumber"))]</InArgument>
<InArgument x:TypeArguments="x:Int32" x:Key="in_RetryNumber">[cint(SystemReserved.Item("RetryNumber"))]</InArgument>
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</Sequence>
</Sequence>
</TryCatch.Try>
<TryCatch.Catches>
<Catch x:TypeArguments="s:Exception" sap2010:WorkflowViewState.IdRef="Catch`1_57">
<ActivityAction x:TypeArguments="s:Exception">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="s:Exception" Name="exception" />
</ActivityAction.Argument>
<Sequence sap2010:Annotation.AnnotationText="Get Exception Information Here. Although you can set an optional Status here, it is recommended you do it in your own try-catch block." DisplayName="Collect and output the exception" sap2010:WorkflowViewState.IdRef="Sequence_400">
<Assign DisplayName="Set SystemError" sap2010:WorkflowViewState.IdRef="Assign_220">
<Assign.To>
<OutArgument x:TypeArguments="s:Exception">[SystemError]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="s:Exception">[exception]</InArgument>
</Assign.Value>
</Assign>
<ui:LogMessage DisplayName="Log exception message" sap2010:WorkflowViewState.IdRef="LogMessage_51" Level="Error" Message="["An exception has occurred: " + exception.Message + " at Source: " + exception.Source]" />
</Sequence>
</ActivityAction>
</Catch>
</TryCatch.Catches>
</TryCatch>
</State.Entry>
<State.Transitions>
<Transition sap2010:Annotation.AnnotationText="No need for any action here, in case of success simply go to next transaction" DisplayName="Success" sap2010:WorkflowViewState.IdRef="Transition_14" To="{x:Reference __ReferenceID0}">
<Transition.Action>
<Sequence DisplayName="Success" sap2010:WorkflowViewState.IdRef="Sequence_382">
<Sequence DisplayName="Go to next transaction" sap2010:WorkflowViewState.IdRef="Sequence_381">
<Assign DisplayName="Increment TransactionNumber" sap2010:WorkflowViewState.IdRef="Assign_202">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("TransactionNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[cint(SystemReserved.Item("TransactionNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
<Assign DisplayName="Reset RetryNumber" sap2010:WorkflowViewState.IdRef="Assign_203">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("RetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[0]</InArgument>
</Assign.Value>
</Assign>
<Assign DisplayName="Reset ContinuousRetryNumber" sap2010:WorkflowViewState.IdRef="Assign_204">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("ContinuousRetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[0]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</Sequence>
</Transition.Action>
<Transition.Condition>[SystemError Is Nothing]</Transition.Condition>
</Transition>
<Transition DisplayName=">Errors, Abort" sap2010:WorkflowViewState.IdRef="Transition_15" To="{x:Reference __ReferenceID1}">
<Transition.Action>
<Sequence sap2010:Annotation.AnnotationText="The condition of the Transition is the following:

1. Process State has failed with a System.Exception that is not a BusinessRuleException
2. The Process has a MaxContinuousRetryNumber greater than 0 - Config.xlsx
3. This was our last failed attempt" DisplayName="Increment Continuous Retry Number and Take a screenshot" sap2010:WorkflowViewState.IdRef="Sequence_383">
<TryCatch DisplayName="Try catch - TakeScreenshot" sap2010:WorkflowViewState.IdRef="TryCatch_41">
<TryCatch.Try>
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke TakeScreenshot workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_138" UnSafe="False" WorkflowFileName="Framework\TakeScreenshot.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="x:String" x:Key="in_Folder">[Config("ExScreenshotsFolderPath").ToString]</InArgument>
<InOutArgument x:TypeArguments="x:String" x:Key="io_FilePath" />
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</TryCatch.Try>
<TryCatch.Catches>
<Catch x:TypeArguments="s:Exception" sap2010:WorkflowViewState.IdRef="Catch`1_58">
<ActivityAction x:TypeArguments="s:Exception">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="s:Exception" Name="exception" />
</ActivityAction.Argument>
<ui:LogMessage DisplayName="Log message" sap2010:WorkflowViewState.IdRef="LogMessage_27" Level="Warn" Message="["Take screenshot failed with error: "+exception.Message+" at Source: "+exception.Source]" />
</ActivityAction>
</Catch>
</TryCatch.Catches>
</TryCatch>
<Assign DisplayName="Increment ContinuousRetryNumber" sap2010:WorkflowViewState.IdRef="Assign_205">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("ContinuousRetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Int32">[cint(SystemReserved.Item("ContinuousRetryNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
<Assign DisplayName="We failed in Process State" sap2010:WorkflowViewState.IdRef="Assign_206">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("RobotFail")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">["Process"]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</Transition.Action>
<Transition.Condition>[SystemError IsNot Nothing AndAlso (SystemError.GetType.Name <> "BusinessRuleException" And CInt(Config.Item("MaxContinuousRetryNumber")) > 0 And CInt(SystemReserved.Item("ContinuousRetryNumber"))+1 >= CInt(Config.Item("MaxContinuousRetryNumber")) )]</Transition.Condition>
</Transition>
<Transition DisplayName="BusinessRuleException" sap2010:WorkflowViewState.IdRef="Transition_16" To="{x:Reference __ReferenceID0}">
<Transition.Action>
<Sequence DisplayName="BusinessRuleException" sap2010:WorkflowViewState.IdRef="Sequence_385">
<Sequence DisplayName="Go to next transaction" sap2010:WorkflowViewState.IdRef="Sequence_384">
<Assign DisplayName="Increment TransactionNumber" sap2010:WorkflowViewState.IdRef="Assign_207">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("TransactionNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[cint(SystemReserved.Item("TransactionNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
<Assign DisplayName="Reset RetryNumber" sap2010:WorkflowViewState.IdRef="Assign_208">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("RetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[0]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</Sequence>
</Transition.Action>
<Transition.Condition>[SystemError IsNot Nothing ANDALSO SystemError.GetType.Name = "BusinessRuleException"]</Transition.Condition>
</Transition>
<Transition DisplayName="Error, Recover" sap2010:WorkflowViewState.IdRef="Transition_17" To="{x:Reference __ReferenceID2}">
<Transition.Action>
<Sequence sap2010:Annotation.AnnotationText="The condition of the Transition is the following:

1. Process State has failed with a System.Exception that is not a BusinessRuleException
2. The Process is allowed to continue because either condition is true:
2.a). MaxContinuousRetryNumber is less than 0, that is to say disabled in Config.xlsx
2.b). This was not our last failed attempt, MaxContinuousRetryNumber is yet to be reached" DisplayName="Error" sap2010:WorkflowViewState.IdRef="Sequence_387">
<TryCatch DisplayName="Try catch - TakeScreenshot" sap2010:WorkflowViewState.IdRef="TryCatch_42">
<TryCatch.Try>
<ui:InvokeWorkflowFile ContinueOnError="{x:Null}" DisplayName="Invoke TakeScreenshot workflow" sap2010:WorkflowViewState.IdRef="InvokeWorkflowFile_139" UnSafe="False" WorkflowFileName="Framework\TakeScreenshot.xaml">
<ui:InvokeWorkflowFile.Arguments>
<InArgument x:TypeArguments="x:String" x:Key="in_Folder">[Config("ExScreenshotsFolderPath").ToString]</InArgument>
<InOutArgument x:TypeArguments="x:String" x:Key="io_FilePath" />
</ui:InvokeWorkflowFile.Arguments>
</ui:InvokeWorkflowFile>
</TryCatch.Try>
<TryCatch.Catches>
<Catch x:TypeArguments="s:Exception" sap2010:WorkflowViewState.IdRef="Catch`1_59">
<ActivityAction x:TypeArguments="s:Exception">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="s:Exception" Name="exception" />
</ActivityAction.Argument>
<ui:LogMessage DisplayName="Log message" sap2010:WorkflowViewState.IdRef="LogMessage_28" Level="Warn" Message="["Take screenshot failed with error: "+exception.Message+" at Source: "+exception.Source]" />
</ActivityAction>
</Catch>
</TryCatch.Catches>
</TryCatch>
<Assign DisplayName="Increment ContinuousRetryNumber" sap2010:WorkflowViewState.IdRef="Assign_209">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("ContinuousRetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Int32">[cint(SystemReserved.Item("ContinuousRetryNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
<If sap2010:Annotation.AnnotationText="IF this is our last attempt" Condition="[CInt(SystemReserved("RetryNumber")) >=CInt(Config("MaxRetryNumber"))]" DisplayName="Determine if next step is new transaction or retry of current one" sap2010:WorkflowViewState.IdRef="If_91">
<If.Then>
<Sequence DisplayName="Go to next transaction" sap2010:WorkflowViewState.IdRef="Sequence_386">
<Assign DisplayName="Increment TransactionNumber" sap2010:WorkflowViewState.IdRef="Assign_210">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("TransactionNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[cint(SystemReserved.Item("TransactionNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
<Assign DisplayName="Reset RetryNumber" sap2010:WorkflowViewState.IdRef="Assign_211">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("RetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[0]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</If.Then>
<If.Else>
<If Condition="[convert.ToBoolean(SystemReserved.Item("isQueueItem"))]" DisplayName="If our object is a QueueItem, then retrying this transaction will be done later" sap2010:WorkflowViewState.IdRef="If_90">
<If.Then>
<Assign DisplayName="Increment TransactionNumber" sap2010:WorkflowViewState.IdRef="Assign_212">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("TransactionNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[cint(SystemReserved.Item("TransactionNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
</If.Then>
<If.Else>
<Assign DisplayName="Increment RetryNumber" sap2010:WorkflowViewState.IdRef="Assign_213">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("RetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[cint(SystemReserved.Item("RetryNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
</If.Else>
</If>
</If.Else>
</If>
</Sequence>
</Transition.Action>
<Transition.Condition>[SystemError IsNot Nothing ANDALSO (SystemError.GetType.Name <> "BusinessRuleException" AND ( cint(Config.Item("MaxContinuousRetryNumber")) <= 0 OR cint(SystemReserved.Item("ContinuousRetryNumber"))+1 < cint(Config.Item("MaxContinuousRetryNumber")) ) )]</Transition.Condition>
</Transition>
</State.Transitions>
</State>
</Transition.To>
</Transition>
<Transition DisplayName="Data Error" sap2010:WorkflowViewState.IdRef="Transition_19" To="{x:Reference __ReferenceID1}">
<Transition.Action>
<Assign DisplayName="We failed in GetSetDataState" sap2010:WorkflowViewState.IdRef="Assign_214">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("RobotFail")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">["GetSetData"]</InArgument>
</Assign.Value>
</Assign>
</Transition.Action>
<Transition.Condition>[SystemError isNot Nothing]</Transition.Condition>
</Transition>
</State.Transitions>
</State>
</Transition.To>
<Transition.Action>
<Sequence DisplayName="Set flags and move forward" sap2010:WorkflowViewState.IdRef="Sequence_388">
<Assign DisplayName="Reset InitRetryNumber" sap2010:WorkflowViewState.IdRef="Assign_215">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("InitRetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[0]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</Transition.Action>
<Transition.Condition>[SystemError is Nothing]</Transition.Condition>
</Transition>
<Transition DisplayName=">Errors, Abort" sap2010:WorkflowViewState.IdRef="Transition_21" To="{x:Reference __ReferenceID1}">
<Transition.Action>
<Sequence DisplayName="Set flags and move forward" sap2010:WorkflowViewState.IdRef="Sequence_389">
<Assign DisplayName="We failed in Init State" sap2010:WorkflowViewState.IdRef="Assign_216">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("RobotFail")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">["Init"]</InArgument>
</Assign.Value>
</Assign>
</Sequence>
</Transition.Action>
<Transition.Condition>[SystemError IsNot Nothing And CInt(SystemReserved.Item("InitRetryNumber")) >= CInt(Config.Item("MaxInitRetryNumber"))]</Transition.Condition>
</Transition>
<Transition DisplayName="Error, Recover" sap2010:WorkflowViewState.IdRef="Transition_22" To="{x:Reference __ReferenceID2}">
<Transition.Action>
<Assign DisplayName="Inc InitRetryNumber" sap2010:WorkflowViewState.IdRef="Assign_217">
<Assign.To>
<OutArgument x:TypeArguments="x:Object">[SystemReserved.Item("InitRetryNumber")]</OutArgument>
</Assign.To>
<Assign.Value>
<InArgument x:TypeArguments="x:Object">[cint(SystemReserved.Item("InitRetryNumber"))+1]</InArgument>
</Assign.Value>
</Assign>
</Transition.Action>
<Transition.Condition>[SystemError IsNot Nothing And CInt(SystemReserved.Item("InitRetryNumber")) < CInt(Config.Item("MaxInitRetryNumber"))]</Transition.Condition>
</Transition>
</State.Transitions>
</State>
</StateMachine.InitialState>
<x:Reference>__ReferenceID0</x:Reference>
<x:Reference>__ReferenceID3</x:Reference>
<x:Reference>__ReferenceID1</x:Reference>
<x:Reference>__ReferenceID2</x:Reference>
<StateMachine.Variables>
<Variable x:TypeArguments="ui:QueueItem" Name="TransactionItem" />
<Variable x:TypeArguments="scg:List(sd:DataRow)" Name="TransactionData" />
<Variable x:TypeArguments="scg:Dictionary(x:String, x:Object)" Default="[New system.Collections.Generic.Dictionary(Of String, Object) From { {"isQueueItem", False}, {"TransactionNumber", 1}, {"RetryNumber", 0}, {"InitRetryNumber", 0}, {"ContinuousRetryNumber", 0}, {"RobotFail", ""} }]" Name="SystemReserved" />
<Variable x:TypeArguments="s:Exception" Name="SystemError" />
<Variable x:TypeArguments="scg:Dictionary(x:String, x:Object)" Name="Config" />
</StateMachine.Variables>
</StateMachine>
<Sequence sap2010:Annotation.AnnotationText="Successful logging for workblock. 
You should also publish the output arguments that you want to make available in the log." DisplayName="wb Logging Successful" sap2010:WorkflowViewState.IdRef="Sequence_409">
<ui:AddLogFields sap2010:Annotation.AnnotationText="Default wb fields
wbStatus
wbState
wbDurationSec" DisplayName="Publish default wb fields" sap2010:WorkflowViewState.IdRef="AddLogFields_109">
<ui:AddLogFields.Fields>
<InArgument x:TypeArguments="x:String" x:Key="wbStatus">Successful</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbState">Ended</InArgument>
<InArgument x:TypeArguments="x:Double" x:Key="wbDurationSec">[convert.ToDouble(now.Subtract(wbStartTime).TotalSeconds)]</InArgument>
</ui:AddLogFields.Fields>
</ui:AddLogFields>
<ui:AddLogFields sap2010:Annotation.AnnotationText="Publish output fields" DisplayName="Add log fields" sap2010:WorkflowViewState.IdRef="AddLogFields_105">
<ui:AddLogFields.Fields>
<scg:Dictionary x:TypeArguments="x:String, InArgument" />
</ui:AddLogFields.Fields>
</ui:AddLogFields>
<ui:LogMessage DisplayName="Log execution ended message" sap2010:WorkflowViewState.IdRef="LogMessage_42" Level="Info" Message="[wbPath + " execution ended with success."]" />
</Sequence>
</Sequence>
</TryCatch.Try>
<TryCatch.Catches>
<Catch x:TypeArguments="s:Exception" sap2010:WorkflowViewState.IdRef="Catch`1_60">
<ActivityAction x:TypeArguments="s:Exception">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="s:Exception" Name="exception" />
</ActivityAction.Argument>
<Sequence DisplayName="Catch, log and rethrow" sap2010:WorkflowViewState.IdRef="Sequence_411">
<Sequence sap2010:Annotation.AnnotationText="Failed logging for workblock. 
You should only set transaction status if you use a QueueItem, otherwise failed logging should remain unchanged." DisplayName="wb Logging Failed" sap2010:WorkflowViewState.IdRef="Sequence_410">
<ui:AddLogFields sap2010:Annotation.AnnotationText="Default wb fields
wbStatus
wbState
wbDurationSec
wbExceptionType
wbExceptionMessage" DisplayName="Publish default wb fields" sap2010:WorkflowViewState.IdRef="AddLogFields_106">
<ui:AddLogFields.Fields>
<InArgument x:TypeArguments="x:String" x:Key="wbStatus">Failed</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbState">Ended</InArgument>
<InArgument x:TypeArguments="x:Double" x:Key="wbDurationSec">[convert.ToDouble(now.Subtract(wbStartTime).TotalSeconds)]</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbExceptionType">[exception.GetType.Name]</InArgument>
<InArgument x:TypeArguments="x:String" x:Key="wbExceptionMessage">[exception.Message]</InArgument>
</ui:AddLogFields.Fields>
</ui:AddLogFields>
<ui:LogMessage DisplayName="Log execution ended message" sap2010:WorkflowViewState.IdRef="LogMessage_43" Level="Error" Message="[wbPath + " execution ended with exception message: "+exception.Message]" />
</Sequence>
<Rethrow sap2010:WorkflowViewState.IdRef="Rethrow_12" />
</Sequence>
</ActivityAction>
</Catch>
</TryCatch.Catches>
<sads:DebugSymbol.Symbol>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</sads:DebugSymbol.Symbol>
</TryCatch>
<sap2010:WorkflowViewState.ViewStateManager>
<sap2010:ViewStateManager>
<sap2010:ViewStateData Id="Assign_225" sap:VirtualizedContainerService.HintSize="314,102">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Assign_226" sap:VirtualizedContainerService.HintSize="314,102">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Assign_11" sap:VirtualizedContainerService.HintSize="314,87">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="AddLogFields_102" sap:VirtualizedContainerService.HintSize="314,154">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="AddLogFields_108" sap:VirtualizedContainerService.HintSize="314,64">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="LogMessage_41" sap:VirtualizedContainerService.HintSize="314,91" />
<sap2010:ViewStateData Id="Sequence_408" sap:VirtualizedContainerService.HintSize="849,198">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="LogMessage_44" sap:VirtualizedContainerService.HintSize="314,91" />
<sap2010:ViewStateData Id="InvokeWorkflowFile_118" sap:VirtualizedContainerService.HintSize="314,87" />
<sap2010:ViewStateData Id="Assign_227" sap:VirtualizedContainerService.HintSize="242,60" />
<sap2010:ViewStateData Id="Comment_1" sap:VirtualizedContainerService.HintSize="314,112" />
<sap2010:ViewStateData Id="If_100" sap:VirtualizedContainerService.HintSize="581,260">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_415" sap:VirtualizedContainerService.HintSize="314,123">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="InvokeWorkflowFile_148" sap:VirtualizedContainerService.HintSize="314,87" />
<sap2010:ViewStateData Id="Sequence_341" sap:VirtualizedContainerService.HintSize="336,632">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="If_73" sap:VirtualizedContainerService.HintSize="750,51">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">False</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="InvokeWorkflowFile_120" sap:VirtualizedContainerService.HintSize="314,129">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="If_74" sap:VirtualizedContainerService.HintSize="750,277">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="LogMessage_46" sap:VirtualizedContainerService.HintSize="314,91" />
<sap2010:ViewStateData Id="InvokeWorkflowFile_121" sap:VirtualizedContainerService.HintSize="314,87" />
<sap2010:ViewStateData Id="Sequence_414" sap:VirtualizedContainerService.HintSize="336,342">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="If_75" sap:VirtualizedContainerService.HintSize="242,51">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">False</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Assign_186" sap:VirtualizedContainerService.HintSize="242,60" />
<sap2010:ViewStateData Id="Sequence_342" sap:VirtualizedContainerService.HintSize="750,275">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_343" sap:VirtualizedContainerService.HintSize="336,123">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">False</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="InvokeWorkflowFile_122" sap:VirtualizedContainerService.HintSize="314,87" />
<sap2010:ViewStateData Id="Sequence_344" sap:VirtualizedContainerService.HintSize="336,238">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_346" sap:VirtualizedContainerService.HintSize="358,525">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Assign_219" sap:VirtualizedContainerService.HintSize="314,60" />
<sap2010:ViewStateData Id="LogMessage_47" sap:VirtualizedContainerService.HintSize="314,91" />
<sap2010:ViewStateData Id="Sequence_399" sap:VirtualizedContainerService.HintSize="336,372">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Catch`1_46" sap:VirtualizedContainerService.HintSize="404,21">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">False</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="TryCatch_33" sap:VirtualizedContainerService.HintSize="418,779">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Assign_192" sap:VirtualizedContainerService.HintSize="464,60" />
<sap2010:ViewStateData Id="ShouldStop_7" sap:VirtualizedContainerService.HintSize="464,22" />
<sap2010:ViewStateData Id="Assign_193" sap:VirtualizedContainerService.HintSize="242,60" />
<sap2010:ViewStateData Id="Sequence_351" sap:VirtualizedContainerService.HintSize="264,184">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_352" sap:VirtualizedContainerService.HintSize="286,308">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="If_77" sap:VirtualizedContainerService.HintSize="464,456">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_353" sap:VirtualizedContainerService.HintSize="633,784">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="InvokeWorkflowFile_125" sap:VirtualizedContainerService.HintSize="314,129">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="If_78" sap:VirtualizedContainerService.HintSize="464,334">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="InvokeWorkflowFile_126" sap:VirtualizedContainerService.HintSize="464,129">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_354" sap:VirtualizedContainerService.HintSize="486,627">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="If_79" sap:VirtualizedContainerService.HintSize="611,775">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_355" sap:VirtualizedContainerService.HintSize="633,926">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Sequence_357" sap:VirtualizedContainerService.HintSize="655,1832">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Assign_218" sap:VirtualizedContainerService.HintSize="314,60" />
<sap2010:ViewStateData Id="LogMessage_50" sap:VirtualizedContainerService.HintSize="314,91" />
<sap2010:ViewStateData Id="Sequence_398" sap:VirtualizedContainerService.HintSize="336,372">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">False</x:Boolean>
<x:Boolean x:Key="IsAnnotationDocked">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</sap2010:ViewStateData>
<sap2010:ViewStateData Id="Catch`1_47" sap:VirtualizedContainerService.HintSize="400,441">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">