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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Linking Barcode on Pow...
Power Apps
Suggested Answer

Linking Barcode on Power Apps Form to Lists

(1) ShareShare
ReportReport
Posted on by 2
Hello. I've set up a form on Power Apps that connects to Lists through SharePoint. However, I'm trying to set up the barcode scanner to fill out a field on the form with text once its successfully scanned the barcode. So when I go through the form submission on Lists, I can see the barcode in its numerical form. Does anyone know the correct formulas and flow for this?
Categories:
I have the same question (0)
  • Suggested answer
    sumit_artesian Profile Picture
    91 on at
     
    Assuming you have a Canvas app with SharePoint as the data source, you want to scan a barcode and have its numeric value saved to SharePoint, and you want the formula for it. Here is how you can set something like this up:
     
    1. Add a Barcode Scanner control to your app.
    2. Set the OnScan property of your barcode scanner to persist the barcode value to a variable. Use this formula: Set(varBarcode, BarcodeScanner1.Value)
    3. Now, if you have a form control in your Canvas app:
      • Unlock the DataCard which corresponds to the barcode numerical value on your list. (DataCards are locked on forms. You have to navigate to the Advanced Properties and unlock them to be able to customize them)
      • Set the EditMode property of the DataCard to View to make it read-only.
      • Set the Default property of your DataCard to: varBarcode
      • Now, when the form is submitted, and SubmitForm(form1) is called, the barcode value gets persisted in your SharePoint List to the field that you configure it to.
    4. Alternatively, if you have a plain old text input instead of a form control in your Canvas app:
      • Set the EditMode property again to View to make the control read-only.
      • Set the Default property of the control to: varBarcode
      • Later, when you call the Patch() function, make sure to bind the SharePoint List column to the value of the text input control. Something like:
      • Patch(Your_SharePoint_List, Defaults(Your_SharePoint_List), {..., BarcodeValue: TextInput1.Text})
     
    This will ensure that whenever your form submits, the numeric barcode value is saved to your SharePoint List.
     
    Please  Does this answer your question 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 answering Yes to Was this reply helpful? or give it a Like! 🩷
  • Suggested answer
    11manish Profile Picture
    2,126 on at
    To populate a form field using a barcode scanner in Power Apps, capture the scanned value using the scanner’s OnScan event and store it in a variable (e.g.,
     
    Set(varBarcodeValue, BarcodeScanner1.Value)).
     
    Then bind this variable to the Default property of the Text Input inside your form’s DataCard and ensure the DataCard’s Update property uses the Text Input
     
    value.
     
    This allows the scanned barcode to be saved correctly to SharePoint when the form is submitted.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 936

#2
11manish Profile Picture

11manish 628

#3
Valantis Profile Picture

Valantis 604

Last 30 days Overall leaderboard