cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Tobias_S
Helper I
Helper I

From predefined E-Mail via text preparation to Wordpress Post

Hello community,

 

I am quite new to Power Automate Workflow builds and some times I am struggling with my thoughts 🙂

 

Maybe you can help me out with the following automation: An E-Mail comes in with the following structure

 

E-Mail Header (to trigger the automation)

+++ The header of a story is provided within three plus symbols (+) +++

After the word wrap, the text area begins with multiple words and

multiple lines of text.

 

Is it possible to filter the text in between the "+++ " and " +++", to save this text as "Headline" for a word press post and the rest of the text as "Text part" for the same word press post?

 

I tried with compose and "replace()" but this does not solve the "extracting" and separation of the two text items within the body of the e-mail.

1 ACCEPTED SOLUTION

Accepted Solutions
v-jefferni
Community Support
Community Support

Hi @Tobias_S ,

 

Do you mean you have emails sent in with below structure?

vjefferni_0-1646813112582.png

 

If so, please see below flow that I made for the test:

vjefferni_1-1646813737233.png

split(replace(outputs('Html_to_text')?['body'],variables('enter'),''),'+++')

vjefferni_2-1646813766422.png

 

Test result as follows:

vjefferni_3-1646813812162.png

 

Hope this helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

View solution in original post

4 REPLIES 4
v-jefferni
Community Support
Community Support

Hi @Tobias_S ,

 

Do you mean you have emails sent in with below structure?

vjefferni_0-1646813112582.png

 

If so, please see below flow that I made for the test:

vjefferni_1-1646813737233.png

split(replace(outputs('Html_to_text')?['body'],variables('enter'),''),'+++')

vjefferni_2-1646813766422.png

 

Test result as follows:

vjefferni_3-1646813812162.png

 

Hope this helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

Tobias_S
Helper I
Helper I

Thank you for your support, @v-jefferni 

 

I tried to re-build your proposed workflow but unfortunately I get stuck 😞 in the beginning I got the notice about mismatching in "String" and "Array"...so I tried also to copy your workflow one by one.

Wordpress-Automation_2.png

 

I still get an error message.

 

Wordpress-Automation_1.png

Hi @Tobias_S ,

 

The enter variable is for get the string of "New line" so you need to input the Enter on your keyboard. Leave it blank will get the error because string variable could not be null.

 

Hope this help.

 

Best regards,

Jeffer Ni

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

Sometimes you cannot see a tree while standing in the forest. That's why I love coding 😄 Result: Now it's working 🙂 thank you @v-jefferni

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

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

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Users online (1,910)