so im making a player customization Gui, how ever i have ran into a problem when you add more accessories then the gui can fit. Im using UIGridLayout to layout every button nicely.
how could i automaticly resize the scrolling frame to fit all of the buttons?
Can you send a image? Btw what part of it are you confused? Cause down in the āCell Sizeā I thing is size of it an the padding I think is the gui between it.
Any UI Gird Style Layout element has a read-only property called AbsoluteContentSize. This property provides a Vector2 value that shows the size used by the UiGridLayout to fit all the GUI elements and the padding between elements.
And then you can use this Vector2 value to modify the ScrollingFrameās CanvasSize. This value is a UDim2 Value but luckily on the API reference for AbsoluteContentSize has code for the exact reason of adapting the size of a Scrolling Frame.