cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

export Attendance Card details (custom action) to SharePoint list

We need to convert  check-in time  (date&time) with AM Or PM, to fill date and time column in a SharePoint list

Please find the below screenshot  to check the time output

check answer 4 

 

KA.jpg

 
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Regular Visitor

Re: export Attendance Card details (custom action) to SharePoint list

use the below expression to convert it to dateTime

 

addSeconds(‘1970-1-1’, add(div(int(triggerBody()?[‘answer4’]),1000), 19800), ‘yyyy-MM-dd hh:mm tt’)

 

kindly change the highlighted value with your corresponding timeZone seconds like india is ahead by 5:30hr so I added 19800

View solution in original post

5 REPLIES 5
Highlighted
Super User II
Super User II

Re: export Attendance Card details (custom action) to SharePoint list

Hi @makpith 

 

Use following expression to get time in AM/PM format(12 hr pattern) 

 

formatDateTime(UtcNow(),'yyyy-MM-ddThh:mm:ss tt')
 
Replace UtcNow() with datetime string form your power automate.
 
-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
Highlighted
Community Support
Community Support

Re: export Attendance Card details (custom action) to SharePoint list

Hi @makpith,

 

Has your problem been solved by @DeepakS 's advice?
If your problem has been solved, You could go ahead and mark the post as solved by clicking “Accept as Solution” so that this thread will be marked for other users to easily identify!

Best Regards,
Community Support Team _ Lin Tu

Highlighted
Regular Visitor

Re: export Attendance Card details (custom action) to SharePoint list

Hi, I've done what you have suggested but it didn't work, please find attached file below:

 

So the Answer that comes directly from kaizala is as the attached file, which is something that should explain the Checkin time.

Checkin Time format.PNG

 

in the below photo i've placed the formula you have suggested and replaced the UTC with the Answer 4

Checkin Format.PNG

 

 

 

 

 

 

 

This is the Error i got, below:

 

Error.PNG

Highlighted
Community Support
Community Support

Re: export Attendance Card details (custom action) to SharePoint list

Hi @makpith,

 

What's the original time format of the Check-in? Are the "1582803512000" total seconds from a timestamp?

 

And seems like it is from the MS Form, could you please share more about the MS Form if it is? Such as the answer type, thank you.

 

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Highlighted
Regular Visitor

Re: export Attendance Card details (custom action) to SharePoint list

use the below expression to convert it to dateTime

 

addSeconds(‘1970-1-1’, add(div(int(triggerBody()?[‘answer4’]),1000), 19800), ‘yyyy-MM-dd hh:mm tt’)

 

kindly change the highlighted value with your corresponding timeZone seconds like india is ahead by 5:30hr so I added 19800

View solution in original post

Helpful resources

Announcements
secondImage

August 2020 CYST Winners!

Check out the winners of the recent 'Can You Solve These?' community challenge!

thirdImage

Experience what's new for Power Automate

Join us for an in-depth look at the new Power Automate features and capabilities at the free Microsoft Business Applications Launch Event.

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Top Solution Authors
Top Kudoed Authors
Users online (3,497)