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 / ForAll Gallery Items t...
Power Apps
Unanswered

ForAll Gallery Items to new Sharepoint list

(0) ShareShare
ReportReport
Posted on by 1,119

Hi there,

For a student attendance app, i am loading the students details from a share point list using gallery. Basically all the student will be by default made present for all the 4 checkpoints. In case any of the student is absent for any checkpoint, only it will be unchecked.

All these records including students who checked and unchecked, i would like to store them in a new share point list.

I read some blogs and video, but not able to achieve what i am looking for. Could any one please help me.

 

venka91_0-1637994897767.png

 

All the student details comes from the master share point list. Class teacher have an option to uncheck the timeslots if the student is absent. So now my goals is to store the record that is edited and record that is not edited. Basically all the gallery items would need to move to the new sharepoint list.

 

Please help.

 

Categories:
I have the same question (0)
  • venka91 Profile Picture
    1,119 on at

    Posting better image.

    Screenshot from 2021-11-27 12-28-48.png

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @venka91 ,'

    Assuming your field '5:30 AM' is a Yes/No field in the list SAL_DAILY, try this

    ForAll(
     Galleryl.Allltems As aPatch, 
     Patch(
     SAL_DAILY,
     {ID:aPatch.ID}, 
     {'5:30AM':aPatch.Checkboxl.Value}
     )
    )

     

    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.

    Visit my blog Practical Power Apps

     

  • venka91 Profile Picture
    1,119 on at

    Thank you. this is worked. But i have come across one more challenge. Since i am storing the gallery result items to new share point list, when i want to reload the data in gallery , i want to display these time slot values from the new share point where my gallery results are stored.

     

    Is this possible ?

    Example, on the below image, my time slot values should be showing the values that are stored in the record from gallery results share point list.

     

    i had a bit idea, i will store the gallery result share point list into collection. and then display values to time slot from the collection.

    But i don't know how do i pull each record and its corresponding values from collection so, the checkbox shows the values.

    Screenshot from 2021-11-27 14-59-50.png

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @venka91 ,

    What are the current Items of the gallery?

  • venka91 Profile Picture
    1,119 on at

    It is coming from my master student data share point list. All our Students data we are maintaining in master_data sharepoint list. I added 6 checkboxes for attendance time slot and as i said before, saving these values into a new share point list called stu_daily.

     

    Class monitor, logs into application on time slot intervals, and check / uncheck values and submit the results. So i wanted to show the checkbox values from my stu_daily share point list,.

     

    Also since i am using patch without any condition, i do not know how do i avoid duplicate record, when the class monitor submit the record again and again for each time slot.

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @venka91 ,

    Can you please post the Items property of the gallery in Text.

  • venka91 Profile Picture
    1,119 on at

    Filter as follows :

    Set(varcampus, ddcampus.Selected.Value); Set(varClass,ddclass.Selected.Value);

    venka91_0-1638011667072.png

    And in gallery Item Property:

    Filter(SAL, campus.Value = varcampus && class.Value = varClass)

     

    SAL is my master_student data share point list.

     

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @venka91 ,

    You are patching to SAL_DAILY, but your gallery is filtered on SAL (so it will not show any updates). You need to also Patch to SAL if you want the updates to be displayed. Are these both lists or is one a collection? Also you are patching to update a specific record, so will not have duplicates (or are these new records)?

     

  • venka91 Profile Picture
    1,119 on at

    SAL and SAL_DAILY are lists. 

    SAL_DAILY will have new records as the attendance needs to be captured everyday.

     

    This is where I am confused how do I make new records and also display the values for existing records.

     

    SAL is used only to pull the list of students from list. So I can generate atteandance and save them as new records in another list as I need the data for everyday. 

     

    No idea I have got so far in what other way I can do it. Pls guide me if you have new ideas on doing this and pls assist me.

  • WarrenBelz Profile Picture
    155,463 Most Valuable Professional on at

    Hi @venka91 ,

    That then raises the question of how and when the records from SAL_DAILY get into SAL. Also if you want new records in SAL_DAILY, this is a better way

    ForAll(
     Galleryl.Allltems As aPatch, 
     Patch(
     SAL_DAILY,
     Defaults(SAL_DAILY), 
     {'5:30AM':aPatch.Checkboxl.Value}
     )
    )

    The ID syntax updates existing records with the same ID as the item in the gallery. 

    So back to the first question - if you want to see records in SAL that you have just patched into SAL_DAILY, they have to be sent to SAL (so when does this happen?) OR change the items of the gallery to refer to SAL_DAILY.

     

    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.

    Visit my blog Practical Power Apps

     

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 April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 610

#2
Haque Profile Picture

Haque 317

#3
WarrenBelz Profile Picture

WarrenBelz 315 Most Valuable Professional

Last 30 days Overall leaderboard