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 / Patch slider value to ...
Power Apps
Answered

Patch slider value to a share point list

(0) ShareShare
ReportReport
Posted on by 568

Hi everyone, 

 

I’ve been trying to patch a slider Value to my share list but I’ve been having trouble with the formula and any help would be great! 

 

Thank you very much! 🙂 

 

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

    Hi @Sahara22 ,

    Is this what you are wanting to do (note the With() statement is only to save typing)

    With(
     {wVal:Slider1.Value},
     Patch(
     Homebase,
     Defaults(Homebase),
     {
     Zone: 
     wVal & 
     If(wVal=1," hr","")
     }
     )
    )

     

    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.

  • Sahara22 Profile Picture
    568 on at

    Hello, 

     

    Thank you for the fast reply. What would I select on the left side? Keep it “text” ?

     

    The idea I’m trying to do is scan two different barcodes (one employee ID and one Equipment ID) to keep track who signed out what equipment and on the same SharePoint line use the slider to input there crew number manually on the app.   Would this scan on the same line all in one individual app session?

    thank you!   

  • Sahara22 Profile Picture
    568 on at

     

    Please see picture to give you an idea. Thanks so much again.

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

    @Sahara22 ,

    Sorry I am a bit lost here comparing this with your original post (you did not mention anything about barcodes).

    You are creating a new record in the List HomeBase where the Zone (I assume this is a Text field) is set according to the Slider value, with a value of 1 resulting in " hr" after the number in the field and anything else having no suffix.

    Also if you put that on the OnSelect of the slider, it will Patch the value every time someone clicks on it. OnChange is not much better as it will Patch very time the mouse button is released.

    If you want to add it with the scanner value in the same record, it needs to be put in the same Patch as the scanner. Also if you are scanning two barcodes, you will have to store one (in a Variable) and then write it all back at once.

     

    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.

     

     

  • Sahara22 Profile Picture
    568 on at

    Thanks for the reply again. Appreciate all your help. 

    sorry to confuse you. I am essentially trying to build an app that scans employee ID and there equipment, time , crew number (manual entry numbers (1-40) ) and zone area (5 zone text boxes to choose from) (manual entry) all on the same line automatically as I check them in through this app. 

    please see pictures. 

     

    I have managed to get the barcode scanner to work to get the employee ID to list and date but what I was looking help for was to when they use the slider on one screen and select a zone on another screen then scan equipment at the end that it all get inputted on one line. I know sounds a bit complicated but I’ve been searching for days for this and any help or idea how to do this would be so appreciated! 🙂 

  • Sahara22 Profile Picture
    568 on at

     

    sorry I added the wrong image , this is the correct one. 

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

    @Sahara22 ,

    Firstly, you set Variables on the OnChange of the Slider and Zone. I would seriously suggest you simply use two Text Boxes for both and forget the slider.
    OnChange of the Zone Text Box

    Set(
     gblZone,
     Self.Text & 
     If(
     Self.Text="1",
     " hr",
     ""
     )
    )

    On the Employee No Text box OnChange

    Set(
     gblEmp,
     Self.Text
    )
    UpdateContext({varScan1,Self.Value)

    and the second one

    UpdateContext({varScan2,Self.Value)

    Then a save button (not sure what you are doing with the second scan)

    Patch(
     Homebase,
     Defaults(Homebase),'
     {
     WhoScanned:User().FullName,
     'Date and Time:Now(),
     'Employee Number':gblEmp,
     Name: Not sure whay you want here,
     Zone:gblZone,
     'Equipment Number':varScan1,
     Title:"Entry"
     }
    )

     

    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.

  • Sahara22 Profile Picture
    568 on at

    Thanks again for the reply. Here’s a preview of the app: 

     

     

     

     

     

     

    This is my barcode formula 

     

    Patch(Homebase,Defaults(Homebase),{Title:"Entry",Item: BarcodeScanner1.Value,Name:LookUp(Employee na WhoScanned:User().FullName, 'Date and Time': Now()});Navigate('Employee Scan Complete',Fade)
     

    So, I don’t have to use a slider if that complicates things but because I have 40 crews I don’t want to take forever finding there number and the slider just would make it faster but if you think that’s best then that’s what I’ll do.  Hope this clarifies things more. 

    thanks again for your efforts and time. 

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

    @Sahara22 ,

    Is this now solved?

  • Sahara22 Profile Picture
    568 on at

    No sorry , I still need your help please.

     

    I’m just confused on how to tie all these formulas together to populate on the same line on the SharePoint list.  So scan two barcodes , two manual entry’s to populate on the same line? 

    ive should the flow of the app above to give you an idea. 

    and here is my Formula :

     

    Patch(Homebase,Defaults(Homebase),{Title:"Entry",Item: BarcodeScanner1.Value,Name:LookUp(Employee na WhoScanned:User().FullName, 'Date and Time': Now()});Navigate('Employee Scan Complete',Fade)
     
    Thanks again.

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