Change Scope of the XML List of Type XML Variable
- Last UpdatedAug 30, 2024
- 2 minute read
The scope (Choose the list item to work on options) of the XML list XML variable can be changed during the runtime. Once the scope is changed, the XML list XML variable will use the changed scope. You can change the scope of the XML list XML Variable using the List Navigator activity during workflow execution. Using this action, you can also navigate the XML list XML variable to another list which has a similar schema.
To change the scope of the XML List XML Variable
-
Click Activities and select List Activities from the options.
-
Drag and drop List Navigator activity.

-
Select the XML variable, for which the scope needs to be changed, from the XML Variable of List Type drop down.
-
Type/select the list name in the List Name or ID field. This property helps to change the list that you need to work on. The list entered here should have the same schema of the list from which the XML variable was created. If you do not want to change the working on list, then leave this field blank. Once you change the list, the XML variable will use the changed one.
-
For example, you have a list called Purchase Orders and another list called Approved Purchase Orders which has the same schema as the Purchase Orders list. If you want to add/update some item in the Approved Purchase Orders, you do not have to create separate XMLvariables for both the list. You can use the same XML variables since both lists have the same schema. In this case, create XML variable for Purchase Orders. Enter the List Name as Approved Purchase Orders and set the scope as New. This will point to the Approved Purchase Orders list and add/update the item in that list.
-
Click the drop-down and select the scope from the options. The available options are Current, New and List Query. Here you can change the scope.
Note: You can also use list id. Id should be inside curly braces. Format to use {ListId}. This is optional and list id need not be given when the list name is provided and vice versa. Also, they can provide both as {ListId}ListName format.