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 Apps
Unanswered

QR data in textbox

(0) ShareShare
ReportReport
Posted on by 8

Hello, I hope you can help me, I have a QR that has information, the information is separated by "|" (pipe) I want to make that when reading the QR Code the information is added in their respective textbox

 

Inventario   |     Car       |       Cost

1152|Civic|250000

 

chinoafroo1_0-1691701806137.png

How could I make them fall into their respective textboxes?

 

thanks for your help

 

Categories:
I have the same question (0)
  • Verified answer
    rpersad Profile Picture
    776 on at

    You can use this code with takes the QR code and splits it using "|" to determine where to split the text, and stores the values into different variables. Then you can set the Default value of each Text Field to the variable.

    With(
     { code: Split(qrCode.Text, "|") },
     UpdateContext( {
     var1: Index(code, 1).Value,
     var2: Index(code, 2).Value,
     var3: Index(code, 3).Value
     } ))
  • chinoafroo1 Profile Picture
    8 on at

    thanks for your help.

    I am using the code and adapting it, but it gives me this error.

     

    chinoafroo1_0-1691703076413.png

    With(
     { code: Split(BarcodeScanner.Barcodes; "|") };
     UpdateContext( {
     var1: Index(code; 1).Value;
     var2: Index(code; 2).Value;
     var3: Index(code; 3).Value
     } ))
  • rpersad Profile Picture
    776 on at

    You have a semicolon in the split function when it is suppose to be a comma

  • chinoafroo1 Profile Picture
    8 on at

    He doesn't accept it either

    chinoafroo1_0-1691705066612.png

     

  • chinoafroo1 Profile Picture
    8 on at

    thank you so much @rpersad 

     

    inside the scanner button I put

    With(
     { code: Split(First(BarcodeScanner.Barcodes).Value;"|")};
     UpdateContext( {
     var1: Index(code; 1).Value;
     var2: Index(code; 2).Value;
     var3: Index(code; 3).Value
     } ))

    and with this I am solved. 😀

  • rpersad Profile Picture
    776 on at

    no problem glad to help

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 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard