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 / Capture OnSelect of Ba...
Power Apps
Answered

Capture OnSelect of Barcode Scanner Control

(0) ShareShare
ReportReport
Posted on by 5

Barcode scanner control only has these two properties:

 

OnScan – Actions to perform when a barcode is successfully scanned.

OnCancel – Actions to perform when a barcode scan is canceled by the user.

 

We want to capture a third scenario when the scanner control is clicked ( before the OnScan is triggered). Usually the button control in PowerApps has OnSelect function which is missing from this control. Do you have any idea on how can we achieve that.

Categories:
I have the same question (0)
  • Verified answer
    v-bofeng-msft Profile Picture
    on at

    Hi @pTaunk ,

     

    Yes, barcode scanner do not have a OnSelect property , but I have a workaround for your reference:

     

    1\Add an other button and set it's OnSelect property to:

    Select(BarcodeScanner1);
    YourOnSelectedEvent;

    2\Set the barcode scanner control's visible property to:

    false

     

    Doing so is equivalent to using your newly created button as an initiator for the barcode scanner, and it also has the OnSelect property.

     

    Best Regards,

    Bof

  • pTaunk Profile Picture
    5 on at

    Hi @v-bofeng-msft ,

     

    Thank you. This worked perfectly for my use case. This is a simple and effective solution that I was trying to over engineer.

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard