Skip to main content

Time zone independent fields for Canvas apps

Headshot of article author Greg Lindhorst

Canvas apps now fully support CDS time zone independent fields.  In the CDS preview connector we had blocked them until they were working properly.  All the work required has now been completed and fully deployed.

Our mission was simple: Canvas and Model-driven apps should show and edit date/time values in the same manner.  Entering a value in one app, of either variety, should display the same value in all other apps.

For example, here is an entity with two time zone independent fields:

Here is an edit form in a Canvas app for this entity (I hid the time portion of the DateOnly, we don’t have a dedicated data card for that yet):

And here is the Model-driven equivalent:

Amazing, right?  I know, this doesn’t seem like rocket science, but it’s actually close – properly handling date/time values with time zones is harder than you would think.   And we aren’t done yet, I think we are in a good place for CDS now but we still have work to do for SQL Server.

I’ve also taken this opportunity to write up all the Canvas data types and notes on how best to use them:

There are a lot of notes on working with date/time values.  Feel free to make suggestions based on your experience too.

Finally, about a week ago I announced that we had added polymorphic lookup support and that it was still being deployed.  That deployment is now complete and you can work with polymorphics in any region.