cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
spamtomas
Advocate I
Advocate I

Creating a gallery with data from two tables and checkbox true if exists in table

I have a problem i need to solve but being fairly new to this i am struggling to get my head into it. If anyone has a suggested way to achieve this please let me know, i would prefer to achieve this via an expression rather than change the data tables that already exist as they used elsewhere. First some background.

 

I have x2 dataverse tables

 

  • ADGroups (with a linked table for ADgroup type). This table contains a list of AD groups per row, name="App - app1", type="App" etc
  • Templates - This contains, name="Template for all staff" AppGroups="App - App1; App - App2".

I have a gallery showing names from the table "Templates". When a user selects a template this shows another screen called "Edit Templates". This screen is going to show the various elements that make up a template.

 

For this to work i have created a new gallery on the screen "Edit Templates" with a label and checkbox. The label needs to show a combination of all the possible available ad groups from the table "ADGroups" and all the items in the "AppGroups" field on the Selected Template. For every item that is in the selected template the checkbox will need to be ticked and for every item not in there the checkbox will need to be unticked.

 

A user will then be able to tick new adgroups and on submitting this will be updated in a new table which is read by another process and actioned and the source tables above updated.

 

I have created the gallery and used collections to gather the data and merge them into one collection but now need to create a new column for the checkbox which doesnt exist in the source table.

1 REPLY 1
Roverandom
Solution Supplier
Solution Supplier

I was a little confused by the title and description of your problem, so I'll answer this last part:

 


I have created the gallery and used collections to gather the data and merge them into one collection but now need to create a new column for the checkbox which doesnt exist in the source table.

This is my fictional list:

Roverandom_0-1660746054373.png

Use the AddColumns function to add a column to a data source.

 

Roverandom_1-1660746182488.png

 

Keep in mind that the column does not exist in the original source.

Was I able to help you in any way?



Hi! I hope I was helpfull. Please always mark the answer that helped you, so others who need it will find it faster.



Roverandom is a book by J.R.R Tolkien. I'm a big fan of his works and as Frodo, Aragorn or Gollum are already widely used, I decided to use this nickname.

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (2,612)