Showing results for 
Search instead for 
Did you mean: 
New Member

Help with expression

Hi All, 


Can someone fix this expression for me. 


contains(triggerOutputs()?['body/{Path}'], outputs('Get_a_row')?['body/MBM 1'], replace('NYS, 'NYS', 'S'))
What I am trying to achieve. 
Updating Row in Excel doc by matching part of the folder path with column title, replacing the current text within the cell from NYS to S when a document is submitted as trigger. If the folder path does not match with the column title I would like the cell to remain NYS. 
Any help with this would be much appreciated. 
Community Champion
Community Champion

@Archiehelp  you expression should be as follows, replace 'celltoreplace' with the actual cell name which needs to be replaced

if(contains(triggerOutputs()?['body/ID'],outputs('Get_a_row')?['body/MBM 1']),replace(outputs('Get_a_row')?['body/celltoreplace'],''),outputs('Get_a_row')?['body/celltoreplace'])


Anna Jhaveri

If I have answered your question, please mark the post as Solved to help other users to identify the correct answer
If you like my response, please give it a Thumbs Up.

Helpful resources

Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Users online (4,620)