cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Change trigger

How i can change trigger from "When work item is created" to "When work item is updated" ?

7 REPLIES 7
Expiscornovus
Super User
Super User

 Hi @Anonymous,


It should be possible by deleting the old trigger action and selecting and configuring the new one. See the animated gif below as an example.

 

Only thing you might need to do is update other actions as well (expressions or dynamic content fields which were used from the original trigger action).

 

Changetrigger_DevOps.gif



Happy to help out! 🙂

Interested in more #PowerAutomate #SharePointOnline or #PowerVirtualAgents content?
Visit my blog, Subscribe to my YouTube channel or Follow me on Twitter


Anonymous
Not applicable

Thank you! Its work!

Anonymous
Not applicable

Can you tell me what I need to specify so that my flow is updated when the state is changed in it?

Expiscornovus
Super User
Super User

Hi @Anonymous,

 

You could use an trigger condition expression to check if the System_ChangedDate is equal to the Microsoft_VSTS_Common_StateChangeDate.

 

Below is an example

I have tested this with a Bug work item for the Scrum process btw. I do not know if this would work with other process. You might need to use other fields.

 

@equals(triggerOutputs()?['body/fields/System_ChangedDate'],triggerOutputs()?['body/fields/Microsoft_VSTS_Common_StateChangeDate'])

 

statechanged.png

 



Happy to help out! 🙂

Interested in more #PowerAutomate #SharePointOnline or #PowerVirtualAgents content?
Visit my blog, Subscribe to my YouTube channel or Follow me on Twitter


Anonymous
Not applicable

I've already tried many options, but nothing works...
Now I will explain how my flows work: I am create initiative and Flow 1 is running, in my process i am configure State, its like New 1, New 2, New 3 etc... I want when i change State from New to New 1, Flow 2 need run. How i can do this ?

Expiscornovus
Super User
Super User

Hi @Anonymous,

 

You can only check if the State field has changed and to which value it has changed. You cannot check what the original value was in a trigger condition.

 

Assuming you are using the Scrum process with a bug work item and you are using the out of the box System_State field you could use the following expression:

 

@and(equals(triggerOutputs()?['body/fields/System_ChangedDate'],triggerOutputs()?['body/fields/Microsoft_VSTS_Common_StateChangeDate']), equals(triggerOutputs()?['body/fields/System_State'], 'New1'))

 



Happy to help out! 🙂

Interested in more #PowerAutomate #SharePointOnline or #PowerVirtualAgents content?
Visit my blog, Subscribe to my YouTube channel or Follow me on Twitter


Anonymous
Not applicable

ok, thank you

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Users online (3,336)