cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Chandu
Helper III
Helper III

How to get Default Selected Gallery Item into DatacardValue of EditForm

In Screen1, I am having PrimaryContactGallery and SecondaryContactGallery respectively. Where in PrimaryContactGallery, List of Primary Contacts is shown and in SecondaryContactGallery, List of Secondary Contacts is shown.

In Screen2, I am Having EditForm1 where Contact DatacardValue Default Property: If(NextArrow1.OnSelect = true,  PrimaryContactGallery.Selected.'Contact', SecondaryContactGallery.Selected.'Contact'), Where NextArrow1 is the Arrow Icon in PrimaryContactGallery.

I am getting error at "NextArrow1.OnSelect = true" Logical Condition in If().

 

Can anyone help me how get default selected contact in EditForm1 from PrimaryContactGallery or SecondaryContactGallery

When NextArrow1 is selected, then Primary Contact must be Shown.

When NextArrow2(Arrow Icon in SecondaryContactGallery) is Selected, then Secondary Contact must be shown in Contact Datacardvalue.

1 ACCEPTED SOLUTION

Accepted Solutions
Viraj009
Regular Visitor

@Chandu 
Create a variable, lets say Set(varContact,""); 

When NextArrow1 is selected, then set its on-select property to Set(varContact,PrimaryContactGallery.Selected.'Contact'); 

When NextArrow2(Arrow Icon in SecondaryContactGallery) is Selected, then set its on-select property to Set(varContact,SecondaryContactGallery.Selected.'Contact'); 
In the DataCard default value set value as varContact.
Hope it helps.

 

View solution in original post

1 REPLY 1
Viraj009
Regular Visitor

@Chandu 
Create a variable, lets say Set(varContact,""); 

When NextArrow1 is selected, then set its on-select property to Set(varContact,PrimaryContactGallery.Selected.'Contact'); 

When NextArrow2(Arrow Icon in SecondaryContactGallery) is Selected, then set its on-select property to Set(varContact,SecondaryContactGallery.Selected.'Contact'); 
In the DataCard default value set value as varContact.
Hope it helps.

 

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (3,094)