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

Gallery OnSelect not working after submitting form

Dears,

 

I have a vertical gallery that consists of a list of items.

 

the OnSelect property of the gallery is:

 

Set(newChild,ChildGallery.Selected)

 

and i have a form, the item property of the form is:

 

newChild

 

finally, i have a button. OnSelect:

 

SubmitForm(ChildForm)

 

when i change the selection in the gallery, the change is reflected in the form. however, after i submit the form one time, changing the selection in the gallery is not reflected in the form. the select button does not seem to do anything.

 

Any ideas?

 

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
khedir
Helper I
Helper I

I figured out the problem causing this problem.

 

the OnSuccess property of the form had this code:

 

NewForm(ChildForm)

 

after removing that, it is working as intended. 

View solution in original post

4 REPLIES 4
RyanVH
Advocate II
Advocate II

You could do this to set the variable

Set(newChild, ThisItem)

If you're updating a record make sure the form mode is set to FormMode.Edit

 

I have done ThisItem, however, after submitting the OnSelect does not work. the form is in edit mode

I tested by adding a label for the selected item. after submission, the on select property is working. However, the form is not being populated with the values.

khedir
Helper I
Helper I

I figured out the problem causing this problem.

 

the OnSuccess property of the form had this code:

 

NewForm(ChildForm)

 

after removing that, it is working as intended. 

Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

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