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

Patch function not working properly on Phone.

Hi all,

 

I've created a time registration function that allows the user to register the time with one push of a button.

The OnSelect property is set to:

Patch(
    TimeData,
    LookUp(
        TimeData,
        Day = DataCardValue35_1.Text And Line = "Blister" And BatchNo = DataCardValue29_1.Text
    ),
    {PrepOperStart: DateTimeValue(Text(Now(), "yyyy mm dd hh:mm"))}
)

This works well on the desktop! But not on the iPhone..?!
Sometimes it appears as if it's executing the function but nothing gets patched to the data source. The data source is a Sharepoint List.

 

However I also created a manual input option where the user can register the datetime to the same field using a standard EditForm control instead. It works on both desktop and iPhone!

What could be the cause for this issue with Patch()?

 

Best regards,

1 ACCEPTED SOLUTION

Accepted Solutions
thomaspp
Helper I
Helper I

Sorry, I found the answer after a couple if hours of trial and error.'

Apparent iOS doesn't recognize this time format 

DateTimeValue(Text(Now(), "yyyy mm dd hh:mm"))

so I changed it to "Now()"...
Shows you the importance of testing on various devices.

View solution in original post

2 REPLIES 2
thomaspp
Helper I
Helper I

Sorry, I found the answer after a couple if hours of trial and error.'

Apparent iOS doesn't recognize this time format 

DateTimeValue(Text(Now(), "yyyy mm dd hh:mm"))

so I changed it to "Now()"...
Shows you the importance of testing on various devices.

v-chenzhi
Community Support
Community Support

Hi @thomaspp ,

 

Thanks for sharing!

I haven't considered the limitations of iOS before. I tried this and it worked.

DateTimeValue(Text(Now(), "yyyy/mm/dd hh:mm"))

I need to know more about this restriction, please mark your post as a solution so help others find it more readily.

Thanks again for sharing!

 

 

Best Regards,

Zhi Chen

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on June 15, 2022 at 8am PDT.

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.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Top Kudoed Authors
Users online (1,662)