Power Community

Power Community

How to create barcode using power automate and scan using power app

In this article, we will learn how we can create bar code with the help of Power Automate and have bar code in SharePoint list as attachment and scan barcodes with the help of Power Apps.

Step 1:

First, we have to go to https://sharepoint.com/, then we must create a team site as preferable.

Now, create a SharePoint list with the following columns.

Rahman1005_0-1709539503198.png

Step 2:

Now go to https://make.powerautomate.com/ click on My flows on left navigation you can able to see new flow on top ribbon from there select automated cloud flow, as show in below screen.

Rahman1005_1-1709539503203.png

Next give the flow name as preferable and choose flow trigger as when an item is created in SharePoint. Refer blow screen.

Rahman1005_2-1709539503210.png

Step 3:

In the “When an item is created” box provide the site URL and select the list name as “Employeelist”.

Rahman1005_3-1709539503211.png

Step 4:

Next click on “Add an action” then search for “Encodian” and select it.

After that search for “Create BarCode” and select it.

Rahman1005_4-1709539503215.png

Next, select “BarCode Type” like code128 or as preferable.

add “Employee ID” then a separator like “|” and “Full Name” SharePoint Dynamic Values in BarCode Data box as shown in blow screen.

Rahman1005_5-1709539503217.png

Step 5:

Next, click on “Add an action”.

Search for “SharePoint”. Then search for “Add attachment” and select it.

Rahman1005_6-1709539503221.png

Step 6:

Then add “Site Address”, “List Name” and “ID” SharePoint dynamic value.

In “File Name” section set the file name as preferable as here “Bar-EmployeeID-Name.jpg” With dynamic value.

Rahman1005_7-1709539503222.png

Step 7:

Click on Save Flow.

To test the flow, click on the Test button from the right side of the top menu and click the Run flow button.

Step 8:

Now go to “Employeelist” in SharePoint.

Added a name here, Barcode has generated as below.

Rahman1005_8-1709539503223.png

Step 9:

Now Go to https://make.powerapps.com/

Next, click on “Create”, and select start from Blank canvas app give the name of your app and click on create.

Rahman1005_9-1709539503230.png

Add a Barcode Reader control to the Power Apps screen and give a text to this control (i.e., Click Here to Scan)

Rahman1005_10-1709539503231.png

Add a Barcode Reader control to the Power Apps screen and give a text to this control (i.e., Click Here to Scan)

Rahman1005_11-1709539503234.png

Next, add a Power Apps Display Form to the Power Apps screen.

Connect that Display form to the SharePoint data source (i.e., Employee List). Go to the right-side Properties Panel > Fileds > Add fields.

Add all the fields to the Display Form. As a result, the form will appear as shown below:

Rahman1005_12-1709539503236.png

By default, we don’t want to display the above data fields when the app will visible.

The data fields will visible only when the user scans a valid barcode. To implement this I have created a variable in the Barcode reader’s OnScan property.

OnScan = Set(VarOnScan, true)

Rahman1005_13-1709539503240.png

Use variable “ VarOnScan” on the display form’s Visible property.

Rahman1005_14-1709539503242.png

Again, insert the below expression on the Screen’s OnVisible control as shown in below screen.

OnVisible = FormViewer1.Visible = VarOnScan

Rahman1005_15-1709539503245.png

Next, add a Power Apps text label control and place it on the display form and add texts to the label control i.e., “Click on The Scanner and Scan the Barcode To Get The Employee Information”

Insert the below expression on the label’s Visible property.

Visible = !VarOnScan

Rahman1005_16-1709539503248.png

Rahman1005_17-1709539503251.png

To display the scanned item’s information, insert the below expression on the Display Form’s Item property.

LookUp(

    EmployeeList,’Employee ID’ = First(BarcodeReader2_1.Barcodes).Value

)

Rahman1005_18-1709539503253.png

Save and publish the app.

Navigate to SharePoint list and create a new items in list.

Now Open the “Employee list”. Click on one of the attachments you can able to find bar code.

Rahman1005_19-1709539503256.png

Now download the “Power Apps” Mobile Application to test the app you have created.

Now, Open the canvas app you have created via mobile application.

Scan the Barcode.

After scanning the barcode, the Employee information is visible in display form in your app as shown in below screen.

Rahman1005_20-1709539535721.png

Thank you..!

This post was originally published on this site

- Advertisement -spot_img

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisement - Advertisement

Latest News

5 Benefits of In-App Notifications for Microsoft Dynamics 365 CRM users

For a successful sales process, you need to stay up-to-date with crucial sales information like deal closures, opportunities won,...

More Articles Like This

- Advertisement -spot_img