cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
LAzerty1
Level: Powered On

Number of lines in a gallery depends on a variable

Dear friends,

 

I'm fighting with a gallery.

 

On my forms i got a Slider which its value is between 0 and 24 both includes. Then i have a gallery where i want to have the same number of row as my slider value.

 

My slider value is stocked in a var "dataValue" and my gallery items function is  : "FirstN(CustomGallerySample;dataValue)" 

 

On this photo you can see that there is 3 row because the value of the slider is 3

But on this one, you can see that my gallery is composed of only 4 rows and that i can have more. In gallery option, scroll bar is activated so i don't know what can I do.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Dual Super User
Dual Super User

Re: Number of lines in a gallery depends on a variable

Hi @LAzerty1 

 

Please update the OnChange property of your slider to:
 
ClearCollect(GalleryRowCount,FirstN([1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],Slider1.Value))
 
Now in the Gallery, please modify the Items property to GalleryRowCount. 
 
Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

2 REPLIES 2
Highlighted
Dual Super User
Dual Super User

Re: Number of lines in a gallery depends on a variable

Hi @LAzerty1 

 

Please update the OnChange property of your slider to:
 
ClearCollect(GalleryRowCount,FirstN([1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],Slider1.Value))
 
Now in the Gallery, please modify the Items property to GalleryRowCount. 
 
Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

LAzerty1
Level: Powered On

Re: Number of lines in a gallery depends on a variable

Thanks a lot ! It works perfect ! @yashag2255 

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 371 members 5,684 guests
Please welcome our newest community members: