cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
randomsky
Helper I
Helper I

Incorrect date displaying in app

I'm using SharePoint as the record source for a canvas app and the data I have in SharePoint for this record is:

randomsky_1-1636697661382.png

But when I see the Date of Birth in the Canvas app, it shows this:

randomsky_2-1636697698940.png

I'm not sure why the date incorrectly displays for the date of birth. Any help appreciated.

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

It seems most likely you are running into a formatting issue, since the example you show is dd/mm/yyyy in stead of the default American formatting.

This can be fixed by changing the Default property of your datepicker to something like the following (replace SPList.DateColumn with the name of your input and "nl-NL" to the country code you use to store the dates):

DateTimeValue(SPList.DateColumn, "nl-NL")

 

View solution in original post

4 REPLIES 4
shoog
Super User
Super User

The DatePicker has a property "StartYear", which is set to 1970 by default, which will cause any date before 1970 to show as 1/1/1970.

You would want to change that to an appropriate value.

I tried changing the "startyear" property to 1940 but now it displays 7/6/1959 as the date of birth, which is still incorrect.

It seems most likely you are running into a formatting issue, since the example you show is dd/mm/yyyy in stead of the default American formatting.

This can be fixed by changing the Default property of your datepicker to something like the following (replace SPList.DateColumn with the name of your input and "nl-NL" to the country code you use to store the dates):

DateTimeValue(SPList.DateColumn, "nl-NL")

 

randomsky
Helper I
Helper I

Thanks @shoog , yes that resolved the issue

Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (2,472)