Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Using Flows
Unanswered

create a calendar event on O365

(1) ShareShare
ReportReport
Posted on by

Hi everybody,

 

I need some help for creating an flow that should create a calendar event.

My flow should look in my calendar for new events created and create a new calendar event in dependency to the new event.

 

First I check for the event subject to filter for some special contents and that is where my problems start.

In my first condition check I have used the following filter "@or(contains(triggerBody()?['Subject'], 'FIRST'),contains(triggerBody()?['Subject'], 'SECOND'),contains(triggerBody()?['Subject'], 'THIRD'))"

So it should check for the event subject if one of the three contents is inside that and go on with the flow or not...

 

But when creating an event I get a failure message:

Unable to process template language expressions for action 'check_subject' at line '1' and column '2469': 'The template language function 'contains' expects its first argument 'collection' to be a dictionary (object), an array or a string. The provided value is of type 'Null'.'. "

 

From that message I would assume that the subject is empty, but it's not... at least not the event I've created

Maybe someone can also tell me how to dig a little deeper in some logs fom MS flow, because I cannot see what event that flow is just processing.

 

Thanks in advance.

Thomas

  • GabrielStJohn Profile Picture
    on at
    Re: create a calendar event on O365

    Hey, @Anonymous!

    Thank you for posting to the Flow Community Forum! It appears you have found a solution to your issue! If you feel as though your issue has been solved and you are satisfied with one of the previous replies, please click "Accept as Solution" on the reply that contains the solution so that this thread will be marked for other users to easily identify!

    Thank you for being an active member of the Flow Community!

    -Gabriel
    Microsoft Flow Community Manager

  • Community Power Platform Member Profile Picture
    on at
    Re: create a calendar event on O365

    Hi @v-yamao-msft,

     

    Well I used another event trigger "When an event is added, updated oder deleted" and changed it now.

    Although it should have worked as I now haven't used any other filter for my first condition check, than only changing the trigger to "When a new event is created", as this would make more sense than my selection before...
    but never the less, it should have worked with the other flow too...
    So I think at first it is solved by changing my trigger to the other one, that fits more.

     

    so thanks for that indirect hint 😉 as I saw the "When a new event is created" from your pictures.

  • v-yamao-msft Profile Picture
    on at
    Re: create a calendar event on O365

    Hi @Anonymous,

     

    Do you want to create an event in a new calendar when an event contains specific subject is created in your calendar?

     

    I have made the following flow, the condition is configured likes below:

    @or(contains(triggerBody()?['Subject'], 'FIRST'),contains(triggerBody()?['Subject'], 'SECOND'),contains(triggerBody()?['Subject'], 'THIRD'))

     

    It just works fine if the subject of the new event contains FIRST/SECOND/THIRD.

    2.PNG1.PNG

     

    Please make sure the event does have a subject and try again with it.

     

     

     Best regards,

    Mabel Mao

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,524 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,906 Most Valuable Professional

Leaderboard

Featured topics

Restore a deleted flow