How to send a document for approval when a major version is published?

  • 18 June 2020
  • 1 reply
  • 5 views

Badge

Hi,

 

I am trying to send a notification to certain users when a major version of a document is saved in the any of the folders in the library.

 

E.g I have created a form that notifies the users of a new inquiry when filled out, it then creates a folder in the library. I want to then notify the users when the document that is made in the folder is published as a major version and needs there approval (only notify when major version not minor).


1 reply

Badge +8

Hi @RainbowLuke,

you can run a workflow on each change and extract the version in a "hacky"-way:

  • Regular Expression
    Pattern: .
    Input: {ItemProperty:_UIVersionString}
    Store result in: some_collection_variable
  • The variable some_collection_variable will then always contain 2 elements, the "major" version and the "minor version". You can extract the minor version using a collection operation:
    Opertation: Get
    Index: 1 (I had to use a variable with a default value as I could not enter a number directly)
    Store result in: number_MinorVersion
  • Place a run if and only send the notification if true
    number_MinorVersion > 0

Reply