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

Gallery and Form dynamic Y Positioning

Hi,

I have a summary form pops up before submitting the form. this summary includes forms and galleries where the user filled in and requested.. my issue is how to make Y position dynamic for each gallery and form if one of them is blank the next gallery or form took its place and avoid white spaces between galleries and forms in the summary page. 

the user sometimes request only one thing of many. in the summary form i need only this one to be on top instead of its fixed Y position.

 

I have tried this but didnt work!

GalleryA.Y = GalleryB.Y +20

but even if GalleryB is not visible still reserving its position!

 

 

Thanks

tempsnip.png

1 ACCEPTED SOLUTION

Accepted Solutions
v-jefferni
Community Support
Community Support

Hi @YAYA ,

 

An easy way to adjust controls is putting them in a Canvas control, you could add a Scrollable screen and find it.

35.png

 

Then you could add Forms and Galleries into each Data Card (you will have to cut and paste since Galleries or Forms could not be put into Data Cards directly):

36.png

 

So here you can set Visible of the Data Cards instead of Galleries and Forms, if Visible of a Card = false, then the whole Card would not only invisible but also disappear from the Canvas, all cards below would elevate and cover it.

 

Hope this helps.

 

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

4 REPLIES 4
v-jefferni
Community Support
Community Support

Hi @YAYA ,

 

Please try:

GalleryA.Y= If(!GalleryB.Visible,GalleryB.Y,GalleryB.Y+GalleryB.Height)

 

Code explaination:

If Gallery B is hidden, Gallery A would share the same Y with it so Gallery A will cover Gallery B, if Gallery B is visible, Gallery A would locate below Gallery B.

 

Hope this helps.

 

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.

Thanks for your help, ya this works if in the summary form only two galliereis. 

 

My Scenario is I have the a sequence as following: 

Form-1

Form-2

Gallery-A

Gallery-B

 

Lets say the user only filled in Gallery-B. so in the summary I don't need Form-1, Form-2 nor Gallery-A and those will be invisible. so Gallery-B should take the place of Form-1.

v-jefferni
Community Support
Community Support

Hi @YAYA ,

 

An easy way to adjust controls is putting them in a Canvas control, you could add a Scrollable screen and find it.

35.png

 

Then you could add Forms and Galleries into each Data Card (you will have to cut and paste since Galleries or Forms could not be put into Data Cards directly):

36.png

 

So here you can set Visible of the Data Cards instead of Galleries and Forms, if Visible of a Card = false, then the whole Card would not only invisible but also disappear from the Canvas, all cards below would elevate and cover it.

 

Hope this helps.

 

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

Thanks, that's what I was looking for 🙂

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (2,636)