# \[TUTORIAL\] Trigger a flow using calendar events

**URL:** <https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017>\
**Category:** Tutorials\
**Created:** [August 26, 2020, 11:37am UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017 "2020-08-26T11:37:14Z")\
**Posts on this page:** 20\
**Page:** 5

<div class="post-metadata">

**Author:** ![Kathrin\_Pilka](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/kathrin_pilka/32/79601_2.png) [@Kathrin\_Pilka](https://community.homey.app/u/Kathrin_Pilka)\
**Post date:** [September 12, 2023, 5:59pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/81 "2023-09-12T17:59:22Z")

</div>

Sure, Here is the report id: 2490758d-578f-4ecc-99ef-173c22ef580c

---

<div class="post-metadata">

**Author:** ![runely](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/runely/32/28153_2.png) [@runely](https://community.homey.app/u/runely)\
**Post date:** [September 12, 2023, 8:58pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/82 "2023-09-12T20:58:50Z")

</div>

I found the bug. Sorry for the inconvenience. I have just released a new version. Can you please install v2.0.3 and let me know how it goes

---

<div class="post-metadata">

**Author:** ![Kathrin\_Pilka](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/kathrin_pilka/32/79601_2.png) [@Kathrin\_Pilka](https://community.homey.app/u/Kathrin_Pilka)\
**Post date:** [September 13, 2023, 7:00am UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/83 "2023-09-13T07:00:18Z")

</div>

Awesome! Thank you. It is working now 🙂

---

<div class="post-metadata">

**Author:** ![Kathrin\_Pilka](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/kathrin_pilka/32/79601_2.png) [@Kathrin\_Pilka](https://community.homey.app/u/Kathrin_Pilka)\
**Post date:** [October 20, 2023, 10:00am UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/84 "2023-10-20T10:00:43Z")

</div>

Hi,

I have the same problem again (I havn’t changed the setup since you did the bug fix). I can’t see the current event that is ongoing.

 ![Screenshot 2023-10-20 at 12.00.11](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/f/2fd680d388378621aa85330f04edab36d6d41422.png)

---

<div class="post-metadata">

**Author:** ![runely](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/runely/32/28153_2.png) [@runely](https://community.homey.app/u/runely)\
**Post date:** [October 20, 2023, 11:38am UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/85 "2023-10-20T11:38:50Z")

</div>

I’m guessing you don’t mean the event in the list, since that isn’t ongoing yet 😛

I’ll need a diagnostics report again.  
Can you do the same as last time:

- Lower the import limit to 1 week
- Activate log all events
- Restart the app
- After a minute or two send a diagnostics report

---

<div class="post-metadata">

**Author:** ![Kathrin\_Pilka](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/kathrin_pilka/32/79601_2.png) [@Kathrin\_Pilka](https://community.homey.app/u/Kathrin_Pilka)\
**Post date:** [October 20, 2023, 11:53am UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/86 "2023-10-20T11:53:08Z")

</div>

Thank you. Yes, the one Event you see here is not the ongoing event. I can not see the ongoing event 🙂

Here is the diagnostic report: a3520e1a-775c-43de-a899-0585b5d6d6bf

---

<div class="post-metadata">

**Author:** ![runely](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/runely/32/28153_2.png) [@runely](https://community.homey.app/u/runely)\
**Post date:** [October 22, 2023, 3:33pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/87 "2023-10-22T15:33:17Z")

</div>

I believe i found the bug. I’ve added the bugfix to **v2.3.0**.

---

<div class="post-metadata">

**Author:** ![DirkG](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/dirkg/32/118897_2.png) [@DirkG](https://community.homey.app/u/DirkG)\
**Post date:** [October 2, 2024, 11:01am UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/88 "2024-10-02T11:01:26Z")

</div>

2 posts were merged into an existing topic: [[APP][Pro] IcalCalendar](https://community.homey.app/t/app-pro-icalcalendar/80708/149)

---

<div class="post-metadata">

**Author:** ![Mattijs\_Brunink](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mattijs_brunink/32/120753_2.png) [@Mattijs\_Brunink](https://community.homey.app/u/Mattijs_Brunink)\
**Post date:** [January 30, 2025, 2:13pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/89 "2025-01-30T14:13:00Z")

</div>

I’m trying to start a flow with a “Event starts in” card. When I put in a number for the amount it’s working fine but when I put in a Variable it’s not triggered.  
Hereby my test script:

 ![Screenshot 2025-01-30 150856](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/3/7/3773d3a3478295b75ad14df644b260fe54b90e9d.png)  
And the result:  
 ![Screenshot 2025-01-30 150452](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/d/a/daf0a007419b946b178eb75b47f2fce4a2e78c26.png)  
I was hoping to see 3 notifications but I only get two, the one with the variable is missing.  
Is there a way that i can use Variables in the “Event starts in” card

kind regards Mattijs

---

<div class="post-metadata">

**Author:** ![Peter\_Kawa](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/peter_kawa/32/173848_2.png) [@Peter\_Kawa](https://community.homey.app/u/Peter_Kawa)\
**Post date:** [January 30, 2025, 2:37pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/90 "2025-01-30T14:37:57Z")

</div>

Very few trigger cards accept variables as value.  
It’s not erroring or such, which is odd. The card just “sees” no value.

---

<div class="post-metadata">

**Author:** ![runely](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/runely/32/28153_2.png) [@runely](https://community.homey.app/u/runely)\
**Post date:** [January 30, 2025, 6:53pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/91 "2025-01-30T18:53:40Z")

</div>

Just tested this on my Homey Pro 2023, and using a variable in the trigger card `Event starts in X minute(s)` works for me from both an advanced flow and a regular flow.

---

<div class="post-metadata">

**Author:** ![Patrick\_Van\_Deursen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/patrick_van_deursen/32/56539_2.png) [@Patrick\_Van\_Deursen](https://community.homey.app/u/Patrick_Van_Deursen)\
**Post date:** [January 30, 2025, 6:55pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/92 "2025-01-30T18:55:23Z")

</div>

also works perfectly in timey:

> **[Timey](https://homey.app/nl-nl/app/no.kjeet90.timey/Timey/)**
>
> Make your time flows dynamic with variables

---

<div class="post-metadata">

**Author:** ![FyX](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fyx/32/50582_2.png) [@FyX](https://community.homey.app/u/FyX)\
**Post date:** [January 31, 2025, 8:13pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/93 "2025-01-31T20:13:47Z")

</div>

I have the same problem, and have done some research on this in recent weeks. I see that I often get the error message  
“TypeError: Cannot convert null value to object” when I try to open a flow on the phone app (android) that have a trigger with a variable.

 ![Screenshot_20250124_103157_Homey](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/0/b/0bb1034726406e56fb5fb240802b31b878d9651c.jpeg)  
I see that flow with triggers with variables often do not work. I have seen in the settings for the IcalCalendar app that it does not register a “hit count” on flow triggers with variables. But it usually works if I have previously tested the flow with a number that matches the variable.

This is on a 2019 Pro.

---

<div class="post-metadata">

**Author:** ![runely](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/runely/32/28153_2.png) [@runely](https://community.homey.app/u/runely)\
**Post date:** [February 9, 2025, 5:03pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/94 "2025-02-09T17:03:33Z")

</div>

I have now tested on both my Homey 2019 (Pro) and my Homey Pro (Early 2023) that triggering the flow card `Event starts in X X` using a number variable or just a number works as it should.

Both flows, one with variable and one with number, triggered simultaneously.

If you have problems with triggering flows with variables, reach out to Athom support. The app itself has nothing to do with you using a variable or a number. It’s Homey core that reads the input and pass along to the apps!

Likewise, if opening a flow containing a variable in a trigger card is throwing an error, reach out to Athom support!

---

<div class="post-metadata">

**Author:** ![Mattijs\_Brunink](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mattijs_brunink/32/120753_2.png) [@Mattijs\_Brunink](https://community.homey.app/u/Mattijs_Brunink)\
**Post date:** [February 10, 2025, 3:33pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/95 "2025-02-10T15:33:12Z")

</div>

> [@runely](#):
>
> ewise, if opening

Can I see your test script?  
the funny thing is, if you have a flow with a number and a flow the a variable at the same time, both flows are working, but if you take out the flow with the number the flow the the valiabel is not working any more…

 ![Screenshot 2025-02-10 161252](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/3/8/3833aa2b4900e2517a3a0ae742f1764e6cf4e621.png)

 ![Screenshot 2025-02-10 161318](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/a/7/a74a6e6ca89eddf42ec24960e78427ae340337f8.png)

 ![Screenshot 2025-02-10 162006](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/4/0/402841c44fbe27178b65d1d471f3a67b3fd2658f.png)

 ![Screenshot 2025-02-10 163245](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/9/1930ce294bed78330587b83cf6f58eed37a17902.png)

---

<div class="post-metadata">

**Author:** ![iBosvelt](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ibosvelt/32/47824_2.png) [@iBosvelt](https://community.homey.app/u/iBosvelt)\
**Post date:** [February 11, 2025, 8:13am UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/96 "2025-02-11T08:13:50Z")

</div>

I think I have discovered the same thing.

I see in the post above that the ‘number’ tag should trigger in 4 minutes, but that doesn’t happen. The ‘number’ tag does not trigger on its own, only when it is a secondary trigger.

---

<div class="post-metadata">

**Author:** ![runely](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/runely/32/28153_2.png) [@runely](https://community.homey.app/u/runely)\
**Post date:** [February 11, 2025, 8:08pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/97 "2025-02-11T20:08:25Z")

</div>

I’ll try this on my Homey’s. However, if this is true, this is still a Homey core issue/problem. As said, the apps receive an integer from Homey core as an argument to the trigger flow. If this integer is from a number directly used in the flow or from a variable which Homey core has read and passed along to the flow, has the apps no clue about.

So still, if you find problems/issues with variables in triggers, contact Athom support.

Screenshots of my flows:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/6/f/6f17c4df1aeddcc44d47590b9a5af8ffe3776faf.png)

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/b/bba68cf5df607d6bbfa43867ab2ed851af859b90.png)

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/7/a/7ac47635b89de9315ff208e98dd06d4e98ce9f86.jpeg)

---

<div class="post-metadata">

**Author:** ![iBosvelt](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ibosvelt/32/47824_2.png) [@iBosvelt](https://community.homey.app/u/iBosvelt)\
**Post date:** [February 11, 2025, 8:22pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/98 "2025-02-11T20:22:00Z")

</div>

Yeah I know… I’ve contacted Athom already. Waiting for their reply… if you test the first 1 with 10 min, and the number logic in 9 or 11 min. Not the same as the first one.

Does the number logic trigger?

---

<div class="post-metadata">

**Author:** ![Mattijs\_Brunink](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mattijs_brunink/32/120753_2.png) [@Mattijs\_Brunink](https://community.homey.app/u/Mattijs_Brunink)\
**Post date:** [February 11, 2025, 10:26pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/99 "2025-02-11T22:26:55Z")

</div>

Using now simple flows but the result is the same. I have now 4 flows, 6 min number, 5 minutes var, 4 minutes number and 4 minutes var. The 6 minutes is working normal, the 5 minutes is not working, and I get 2 messages on the 4 minutes, one from the number and one from the var

 ![IMG_5985](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/3/8/384e38e238a945f9a8e53f4bbcd04f6d670cfd22.jpeg)  
 ![IMG_5984](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/e/7/e7f7a106d33aa2ded1f286b6a004dd7258242bf4.jpeg)  
 ![IMG_5983](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/e/0/e0ace233160e92ea774088bcb9abc2096ea94c2d.jpeg)  
 ![IMG_5982](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/f/8f41292ac48de069ff23476ead4539feffa58785.jpeg)

 ![IMG_5986](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/6/d/6d2934d555f638dec16ebf094d7f09b910d36775.jpeg)

---

<div class="post-metadata">

**Author:** ![runely](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/runely/32/28153_2.png) [@runely](https://community.homey.app/u/runely)\
**Post date:** [February 15, 2025, 1:33pm UTC](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017/100 "2025-02-15T13:33:36Z")

</div>

I managed to recreate this on my homey’s as well, and in fact, I think this is caused by a bug in the app.

I have been running a test version on my development homey which seems to be working as it should.

I’ll release this as a test version soon. Would appreciate if you guys would give the test version a go

[Previous page](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017.md?page=4)

[Next page](https://community.homey.app/t/tutorial-trigger-a-flow-using-calendar-events/34017.md?page=6)
