How i can make infinite scrolling frame with Canvas Size?

What do i want to achieve?

make an infinite scrolling frame whose canvas size in relation to the number of children in it to see them all with a UIListLayout or UIGridLayout.

What solutions i have tried so
I tried looking on the DevForum for my problem but each time I try it doesn’t work.

Thank you to everyone who can help me and happy new year to you :tada:

1 Like

You mentioned resizing the canvas to fit it’s children’s size and position. To do this you can use a relatively new feature, ScrollingFrame | Roblox Creator Documentation. It is an Enum | Roblox Creator Documentation value that defines how the canvas will automatically resize to fit it’s children.

As for the infinite scrolling, I assume you mean a system in which one ends up at the top again after having scrolled to the bottom. To achieve this effect I’m guessing you can read, process, and set the ScrollingFrame | Roblox Creator Documentation property.

5 Likes

Maybe once the player scrolls to the bottom you can increase the CanvasSize?

I’m not sure if this would work since I think that theres a hard limit to the size of the canvas. However, while I may be mistaken, this limit may have also been increased with the automatic sizing update. Nevertheless, this approach still has a limit. Better to create the illusion of infinite scrolling than to actually do so. You may have to disable the scroll bar to do so though.

1 Like

why do u want an inifinite scrolling frame? and also just resize it to the size u need it to be.
-check the number of children
-multiply the number by the size of each frame
-resize the scrolling frame to that size
pretty straight forward

1 Like