Actions

The Actions tab is used to perform the actions when the object enters to a certain state.



The "Actions" tab of the state properties.

Set permissions, Delete and Mark for archiving

You can define new permissions to be set, the object to be deleted, and/or archiving to be performed as a result of a state transition. Several options of the Actions tab can be selected at the same time.

Do not use automatic permissions

As a result of this state transition, the object bypasses the automatic permissions that would normally be applied to the object, and the effective permissions for the object version are configured with the Set permissions feature. However, if a user modifies the object, the automatic permissions are re-applied to the object.

Ignore the permissions of the latest checked-in version for this version

The permissions of the objects are version-specific in M-Files. In order for you to access the latest object version, you must have at least read access to it. To access any of the previous versions, you must have at least read access to that specific version and to the currently latest version. Enabling this checkbox ignores the permissions of the latest checked-in version and grants users access the prior versions of the object to which they have at least read access rights – regardless of the permission settings of the latest version.

This feature merits an example: Let's suppose that we have an SOP and an SOP workflow with the states Draft, Waiting for Approval and Approved. All three states have different permissions, as a draft is shown only to the user who created the document, and an approved document is shown to all users.

The document is now at version 3 and in the Approved state (and thus visible/accessible to all users). As modifications need to be introduced, it is moved back to Draft state and the permissions are changed so that only the creator of the document can see it. If the checkbox Ignore the permissions of the latest checked-in version for this version was active when the new version was created, all users would still be able to access the document version 3, but not the newest one. If the checkbox was not active, however, only the creator of the document would be able to see the document version 3.

Assign to user

Assignments are an important part of workflows. They transfer information and responsibility for task execution to the correct person automatically during a state transition. M-Files offers two types of assignments for use in connection with workflows.

By selecting Assign to User, you can create an assignment that does not result in a separate object. An assignment created with this option is switched to the "complete" state when one of the persons to whom the task was assigned changes the document state in the workflow (usually by moving the object to the next state).



Define the task in the Assignment dialog.

In the object's properties, you can see whom it has been assigned to, provided that the object is in a state to which an assignment is related.

The person to whom the task was assigned can change the state by using the functions in the task area, metadata card or context menu.

Create separate assignment (advanced)

You can create separate assignments as well, in which case the assignment results in a separate object. To create such an assignment, select Create separate assignment. A separate assignment differs from an integrated assignment also in that all persons to whom the task was assigned must mark the assignment as complete to move it to the "complete" state.

In addition, if you want the workflow state to be changed after completion of a separate assignment, you must activate the automatic state transition condition Change state after a separate assignment has been marked as complete.

Adding and Removing users

You can manage the persons responsible for the task by using the Add... and Remove buttons in both the Assign to User dialog and the Create separate assignment dialog. In addition to adding users via the Users or user groups list, you can add users based on metadata or a state transition. For example, a person who has been specified in the property Approved by in the object's metadata can automatically be specified as the person to whom the task is assigned. For more information, see Permissions under State-Transition Permissions and Pseudo-users.



Selecting a user based on an earlier state transition.

Monitoring

In the Monitoring section (Actions > Create separate assignment (advanced) > Monitoring), you can define the users that you want to notify each time that a task is marked as complete. The assignment submitter is automatically defined as a task monitor.

If an assignment is a separate object, all persons to whom the task was assigned must mark the assignment as complete before it is switched to the "complete" state.

There are separate icons for uncompleted and completed assignment objects, making it easy to distinguish between uncompleted and completed assignments.

Assignment description

Add a free-form description of the task. The assignment notice by email displays the description to the person to whom the task was assigned. Notification templates supported by M-Files can also be included in the description. For more information on notification templates and placeholders, refer to Notification Settings (M-Files Admin).

Deadline

If desired, you can specify a deadline for the assignment. The user gets an automatic reminder if he or she has not marked the assignment as completed when the deadline is approaching. The reminder will be sent using a common notification rule which can be deleted by the administrator, if desired.

The deadline can also be useful for creating views. The administrator or user can create a view to display any assignments with an approaching deadline. For more information about views, refer to New View.

Send notification

To send a notification, first define the recipient users and user groups. Then enter the notification subject and the message. You can also specify the user from metadata or state transitions.

The Add Placeholder... buttons can be used to insert values from the object metadata to the subject line or message content (see also Placeholder descriptions under Notification Settings (M-Files Admin)).

Set properties

You can define different object properties and values to be applied when an object's state is changed. For example, you can make the Published version label to be assigned to a drawing when the drawing moves to the Approved state.

Convert to PDF format

Files of the object can be automatically converted into PDF form on the server when the object changes state. Conversion to PDF on the server can be done for files in such source formats as Word, Excel, PowerPoint, Outlook, and Visio, as well as RTF and OpenOffice files.

When converting to PDF, M-Files updates the M-Files property fields, if any, in Word and Excel documents by using the current metadata of the object.

Conversion settings

When you activate the Convert to PDF function from the Actions tab, M-Files converts the files in a single-file or multi-file document to PDF form automatically when the object's state changes. You can define advanced settings for the conversion.

Store each PDF file as a separate file next to the original file: If you also want to keep the file in its original format, select to store the PDF file next to the original file. Then the PDF file does not replace the original. The PDF file is created with the same name as the original file. If this function is applied to a single-file document, M-Files changes it into a multi-file document when creating the PDF file.

Overwrite existing PDF files: If there are already PDF files with this name in the multi-file document, select this option if you want to overwrite the identically named existing PDF files with the versions created via this function. If this option is not selected and the multi-file document already has a PDF file with the same name, M-Files will notify of the error and the PDF file will not be created.

Convert to PDF/A-1b: Select storage in PDF/A-1b form when you want to comply with ISO standard 19005-1:2005 for long-term preservation of electronic documents. PDF/A-1b is a more restricted format than that of standard PDF files, so files converted to PDF/A are often bigger than files converted to standard PDF. In addition, in export to PDF/A, certain advanced appearance settings may be omitted. You should use conversion to PDF/A form only if it is particularly necessary on account of, for example, requirements for long-term preservation.

Prevent state transition if the object contains files in an unsupported format: Select this if you want to prevent the state transition in cases wherein the PDF conversion function encounters files with formats that cannot be exported as PDF files (for instance, ZIP files). An error message is displayed and the state transition is prevented.

Run script

Operations can be specified in more detail using variables, generic features of VBScript, and M-Files API. For example, you can set consecutive numbers for different publication versions or add the send date for a document when it moves to the Sent state.

The following variables can be used in this script: VaultSharedVariables, MFScriptCancel, CurrentUserID, Vault, DisplayID, ObjVer, PropertyValues and StateID. For more information about variables, refer to VBScript Variables Explained.

Note: The administrator must already be familiar to VBScript programming language. Instructions for writing the VBScript code is not included in M-Files or M-Files API documentation. The documentation for the M-Files API is installed in the folder Start / Programs / M-Files / Documentation / M-Files API. For more information about VBScript code and M-Files API, contact [email protected]. Instructions on writing VBScript code and working with the M-Files API are available from the M-Files technical support staff for a separate fee.