cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PDRC
Helper I
Helper I

How to get dropdown selection to check/uncheck the checkbox

Hello everyone,

I have stuck on an issue
I have below tables with me in dataverse

PDRC_0-1668502431002.png

In canvas I have to assign the document to particular employee
I have a dropdown connected to the shared Doc and from there I am getting all the documents in dropdown 
I have a gallery connected to the Employee , check + employe name

PDRC_1-1668502785927.png

if I select any documnet from dropdown it should show that to whom it is assign in the gallery with check & if not assigned It should show uncheck
and if I check any uncheck box that particularly document should get assign to the that employee in the Employee shared document Database

if it is possible please let me know how to do it.

1 ACCEPTED SOLUTION

Accepted Solutions
v-jefferni
Community Support
Community Support

Hi @PDRC ,

 

Based on your description, I have made a simple test for your reference.

 

Here are my tables, I assume there is no relationship created among them so there are no LookUp columns but only text columns:

vjefferni_0-1668671369651.png

vjefferni_1-1668671369658.png

vjefferni_2-1668671369659.png

Here is my test app:

 

Formula for Default property of Check box:

 

!IsEmpty(Filter(EmployeeSharedDocs,Documentname = Dropdown1.Selected.DocumentName,Employeename = ThisItem.EmployeeName))

 

 

Formula for OnCheck property of Check box:

 

Patch(EmployeeSharedDocs,Defaults(EmployeeSharedDocs),{Employeename:ThisItem.EmployeeName,Documentname:Dropdown1.Selected.DocumentName})

 

vjefferni_3-1668671369673.png

vjefferni_4-1668671369680.png

 

Result:

vjefferni_5-1668671369684.png

vjefferni_6-1668671369686.png

 

Best regards,

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

View solution in original post

2 REPLIES 2
v-jefferni
Community Support
Community Support

Hi @PDRC ,

 

Based on your description, I have made a simple test for your reference.

 

Here are my tables, I assume there is no relationship created among them so there are no LookUp columns but only text columns:

vjefferni_0-1668671369651.png

vjefferni_1-1668671369658.png

vjefferni_2-1668671369659.png

Here is my test app:

 

Formula for Default property of Check box:

 

!IsEmpty(Filter(EmployeeSharedDocs,Documentname = Dropdown1.Selected.DocumentName,Employeename = ThisItem.EmployeeName))

 

 

Formula for OnCheck property of Check box:

 

Patch(EmployeeSharedDocs,Defaults(EmployeeSharedDocs),{Employeename:ThisItem.EmployeeName,Documentname:Dropdown1.Selected.DocumentName})

 

vjefferni_3-1668671369673.png

vjefferni_4-1668671369680.png

 

Result:

vjefferni_5-1668671369684.png

vjefferni_6-1668671369686.png

 

Best regards,

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

PDRC
Helper I
Helper I

Hello @v-jefferni 
Thank you so much for the help.😊

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 (5,130)