The Issue with PowerApps and SharePoint Calendars

Notes and Insights

Contents

Notes and Insights

Other stuff I learned that you might find helpful

How to check your Time Zone in Dynamics 365

Dig for it

This item is buried in the Power Platform Admin Center:
Admin Centers > Dynamics 365 > Select your Instance > Open > Gear icon in upper Right Hand Corner > Personalized Settings
The default is (GMT – 11:00) Coordinated Universal Time – 11

Microsoft References I used quite a bit

Bueno

Microsoft has published a great list of all the functions, operators, etc. for PowerApps.  You’ll reference this often

General Info on working with dates and times

Converting to UTC

Functions that work, and functions that are distorted

drooping time

The Value functions for date/time do work– but otherwise, I found the rest of the date/time functions are useless, and can seriously jack-up the data for SharePoint dates.

Examples of date/time value functions:

  • MM/DD/YYYY
  • DateTimeFormat.LongTime (any of the long, short, 24, etc)
  • [$-en-US]h:mm AM/PM]

Examples of date formulas:

  • DateDiff (used to show the difference between 2 dates)
  • DateAdd (see exception below)

Exception:

  • DateAdd is necessary to convert the format of a date to the TimeZoneOffset. In this scenario the function works

Some of the other approaches I tried, but they didn’t work

FAIL smashing on Beth

In SharePoint, create a calculated column = [End Time] – [Start Time].  My theory was that on an all-day event this would be 1-minute less than a full day, or 0.999305556 of a full day.  Then I could do calculations based on items that were less than 1.0.  FAIL

Another theory I worked on was a concept that maybe calculations between SharePoint & Power Apps rounded-up, so that something that was 1-minute less than 24-hours in SharePoint, ended up being more than 24-hours to PowerApps.  Therefore, adding an extra day.  The way around this would be to perform a round-down calculation in SharePoint as a calculated column = RoundDown ([EndTime] – [StartTime], 0)  FAIL

Highlighting important Events

Important Date

I use a simple technique throughout my SharePoint ecosystem to identify important stuff, and then have that importance expire automatically on a certain date.

It requires 2 metadata columns that I set-up as “Universal Site Columns” that propagate to all my sites automatically.  (note that universal site column is my term, not an official one)

For important events, news articles, etc. your Contributors only need to check “Yes” it is an important event, and pick the date that its importance expires.  You can then automate all sorts of things to deliver “ads” for these items on your intranet.

In my Power App template, this is  the technique that highlights important events with a red rule around the date.

You can learn step-by-step how to implement this easy solution

Ad

Do you want to see all this in action?

working on computer

Feel free to download version 2 of my PowerApp template and tear it apart if you want to see the formulas in action.

Additional Help Needed

lost and spinning

I’m a citizen developer, who knows enough to get by, figure stuff out, and sometimes get myself in trouble.  There’s some formulas that are beyond my skills that I would love to figure out formulas for.

If you’re so inclined, and willing to give-back to the community, I’d love your help on figuring out the following formatting formulas in my Company Happening Power App template.

  1. Hide the End Day and Date if the start and end dates are the same
  2. Hide the End Time for “All Day events

These would have to be separate calculations to accommodate multi-day “All Day” events.

Here’s examples of how this would look:

Help-1
Help-2
Help-3

If you’re willing to help, just download my Company Happenings PowerApp template, and dive on in and reach out to me at Beth.Hall@StraightenTheMaze.com.

Thanks!

 

How useful was this information?

Click on a star to rate it

We are sorry that this post was not useful for you!

Let us improve this post!