Edit Items
This custom SharePoint workflow activity is designed to edit items in a specified SharePoint list. The activity allows you to define which items should be edited based on a set of conditions and which field values should be updated. It also includes options for narrowing the query to a specific folder and deciding whether or not to include subfolders. After the items are edited, the workflow can store the IDs of the modified items in a specified variable.
Required parameters:
- Connector The connector used to perform the update on the SharePoint list. This parameter ensures that the workflow can connect to the specified list and perform the necessary operations. Usage: Select the appropriate connector to establish a connection with the target SharePoint list.
- SharePoint list SharePoint list containing the items you want to edit. Usage: You need to specify the name or identifier of the list that contains the items to edit.
- Filter list items Parameter Specifies the conditions that elements must meet in order to be eligible for editing. For example, you can filter by specific fields or item properties.
- Fields values This parameter specifies the fields and their new values for elements that meet the filtering conditions. You should specify the field names and corresponding new values that should be applied to the selected elements.
Optional parameters:
Search in folder Narrows the query to a specific folder within the specified list. If left blank, the query will apply to the entire list.
Include in folders Specifies whether the query should include items in subfolders. This parameter is checked by default, meaning subfolders are included. If you do not want to include items from subfolders, uncheck this option.
Output parameter: Edited item IDs - you can select a workflow variable to store the IDs of the edited items.
Funkcjonality When the user launches an action with an edit items activity, the first step will be to validate the input data, i.e. check that the required parameters are provided and correct. The next step performed by the activity is to establish a connection to the SharePoint list. The activity then sends a query to the SharePoint list to identify items that meet the filtering conditions specified in the Filter List Items parameter. If the Search in Folder parameter is specified, the query will be limited to the specified folder in the list. If the Include Subfolders specifies option is checked, items from subfolders will be included in the search. By default, subfolders are included unless this option is unchecked. The activity then updates the fields of the filtered items based on the values specified in the Fields Values parameter. After the items are successfully edited, the activity stores their IDs in the workflow variable specified in the Edited Item IDs output parameter.
Activity for the current item:
The item editing activity can also be performed for the current item. To do this, in the activity form, select the checkbox next to the value of the current item. After checking the checkbox, the current list/library in the SharePoint list field will be automatically selected. The fields SharePoint list, Filter list items, Search in folder and Include subfolders will become uneditable.
You will be able to edit the fields value field, as well as the
output parameter field Edited item IDs. For this action, the current item will be edited.