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

BUG - Form control inside Layout Container doesn't wrap properly

In my Forms (or any canvas control) the cards won't appear side by side when the form is placed inside a Horizontal or Vertical Layout container. I've tried using "Snap to columns" and turning it off and setting Parent.Width/2 on the cards.

If I remove the Form from the layout container and use a regular container it's fine. The only workaround is to put the Form inside a normal container, which is then inside the layout container. At that point the Form's dimensions need to be set to Parent.Width and Parent.Height. Seems like a bug.

 

Here is the form inside a normal layout container
Screenshot 2021-05-04 082837.jpg

The container dimensions are set manually, Form1 dimensions are set to Parent.Width and Parent.Height

All the cards have a width property equal to Parent.Width/2

Screenshot 2021-05-12 151613.jpg

 

But when you put that same form inside a Layout Container. The Align (vertical) property is set to Stretch and the Form is set to have a Flexible width.
Screenshot 2021-05-12 152040.jpg

The form behaves strangely. When the container is manually resized to a smaller width, the cards shrink correctly and appear side by side. However, when the container is resized manually to a larger width, the cards all stack. It seems to still respect the Parent.Width/2.

Screenshot 2021-05-12 152240.jpg

 

This is obviously an issue for responsive apps.

 

My workaround currently is to put the form inside a regular container, inside a layout container. The Form then has dimensions of Parent.Width and Parent.Height. The regular container has FlexibleWidth turned on and the layout container's LayoutAlignItems property is set to Stretch.

Screenshot 2021-05-12 152402.jpg

 

0 REPLIES 0

Helpful resources

Announcements
User Group Leader Meeting January 768x460.png

Calling all User Group Leaders!

Don't miss the User Group Leader meetings on January, 24th & 25th, 2022.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (1,589)