web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Barcode scan and patch...
Power Apps
Unanswered

Barcode scan and patch data into sharepoint

(0) ShareShare
ReportReport
Posted on by

Hi All,

I am trying to develop app, when operator start to do an order, he will scan and the 1st scan of that particular orderno will patch data into sharepoint the order no, product, process, start.

when the job is finished for that orderno, the operator again scan the same barcode and this time it will lookup the orderno and patch the finish time for the order.

 

 

1.JPG

Set(
 ExistingOrder,
 LookUp('Aluminium Output', Orderno = BarcodeScanner1.Value));
If(
 IsBlank(ExistingOrder),
 Patch(
 'Aluminium Output',
 Defaults('Aluminium Output'),
 {
 Orderno:BarcodeScanner1.Value,
 Start:Now(),
 Product:Product.SelectedText.Value,
 Process:Process.SelectedText.Value,
 Operator:Operator.SelectedText.Value
 }),
 Patch('Aluminium Output',
 ExistingOrder, { Finish: Now() }))

 2.JPG

the issue at the moment with the formula is, same order no has different process, so i am not getting any registry if i scan different process for the same order.

 

i am stuck now, on what formula to modify so for the 1st scan of the order it will simply make the registry with start date/time, for the second scan it will lookup the process value and if the order no & process selection matches it will patch the date/finish time for the order, if the same order has different process selection it should create a new registry .

 

any help is highly appreciated.

 

Regards.

 

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    153,084 Most Valuable Professional on at

    Hi @Anonymous ,

    Using your structure, try this

    Set(
     ExistingOrder,
     LookUp(
     'Aluminium Output', 
     Orderno = BarcodeScanner1.Value
     )
    );
    If(
     IsBlankl(ExistingOrder.Product),
     Patch(
     'Aluminium Output',
     Defaults('Aluminium Output'),
     {
     Orderno:BarcodeScanner1.Value,
     Start:Now(),
     Product:Product.SelectedText.Value,
     Process:Process.SelectedText.Value,
     Operator:Operator.SelectedText.Value
     }
     ),
     Patch(
     'Aluminium Output',
     {ID:ExistingOrder.ID}, 
     {Finish: Now()}
     )
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • WarrenBelz Profile Picture
    153,084 Most Valuable Professional on at

    Hi @Anonymous ,

    Just checking if you got the result you were looking for on this thread. Happy to help further if not.

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • Community Power Platform Member Profile Picture
    on at

    Hi @WarrenBelz ,

     

    Thanks for help.

     

    Sorry for late reply. i tried but it is only making 1st registry for an order no, but when i change the operator & process for the same orderno it is not making any registry.

     

    because each order no has 3 process - cutting, drilling,packaging and those 3- process will be done by different or same people.

     

    example, when i scan orderno: SP001, Name: Jhon, Product:Door,Process: Cutting.

     

    it is making a start and finish time registry in sharepoint.

     

    but when i change the process for same order no, it is not making registry in sharepoint

    example, orderno:SP001,Name: Boris,Product:Door,Process:Drilling.

     

    it will be very helpful if you can help me with this issue.

     

    Thanks in advance.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 739 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard