Hi
I am trying to get calendar meetings which ended until current localtime. I am collecting 1 week old meetings and collecting top 200. Below is the formula. I dont see todays meetings and sometimes i see todays meeting but not all meetings. I see some kind of time conversion issue. Any suggestions would be helpful
Filter(Office365.V4CalendarGetItems(varCalendarID,{'$top':500}).value,DateTimeValue(start)>=Today()-7 && DateTimeValue(end) <=Now()),"start",Descending)
Thanks
Solved! Go to Solution.
The Now function returns current date and time, that's why you sometimes see some of the calendar items, because it depends what time you run the query. use the Today function instead, and change your formula to < DateAdd(Today(),1) this will make sure that your items are less than tomorrow 12:00 AM
--------------------------------------------------------------------
Please Accept as Solution if this post answered your question so other members can find it. If you found this post helpful consider giving my post a Thumbs Up!
The Now function returns current date and time, that's why you sometimes see some of the calendar items, because it depends what time you run the query. use the Today function instead, and change your formula to < DateAdd(Today(),1) this will make sure that your items are less than tomorrow 12:00 AM
--------------------------------------------------------------------
Please Accept as Solution if this post answered your question so other members can find it. If you found this post helpful consider giving my post a Thumbs Up!
Thanks for solution. It solved almost except in one scenario. Reason i was using Now() not to retrieve meeting which was current happening. With your solution i was able to get meetings which were missing and also seeing meeting currently happening. Any other way of excluding meeting which did not end based on current time.
Thanks
and if you need to see the appointment up to current time (Date and Time), you need to convert the datetime from UTC to your current time. The outlook connector, returns all dates in UTC format. you can change them to the user local time:
my items are in a Gallery, that's why I'm using ThisItem.
DateAdd(DateTimeValue(ThisItem.start), -TimeZoneOffset(DateTimeValue(ThisItem.start)), Minutes)
Thanks for idea and driving me in correct path. i kept below formula and it seems to be working. i still have to do extensive testing but results seems to be promising
DateAdd( Now(), TimeZoneOffset(), Minutes)
User | Count |
---|---|
8 | |
7 | |
4 | |
2 | |
2 |
User | Count |
---|---|
5 | |
5 | |
4 | |
4 | |
4 |