Help with Automatic Canvas Size

I have an issue with automatic canvas sizing, it is not changing the size of the canvas as it should do. Is there any other way to resize a canvas. I am using UIListLayout inside the scrolling frame…
I even tried this but still didn’t work

self.ScrlFrame.CanvasSize =, 0, 0, self.List.AbsoluteContentSize.Y)

Set the scrolling frame canvas size everytime AbsoluteContentSize of UIListLayout changes.

I tired that earlier but it doesn’t work

Are you sure your code is getting to that line?


this is that like of code, self.List is UIListLayout

local function update()
    local y = self.ScrlFrame.List.AbsoluteContentSize.Y
    self.ScrlFrame.CanvasSize = UDim2.fromOffset(0,y)


yep, that’s the same thing I have done, but it’s not working

I am not sure why but,
and using print(self.List.AbsoluteContentSize.Y) at the end of the script (after all the changes to the scrolling frame is done), it’s printing 104

umm it works now, I had forgot to parent the scrolling frame from nil to the screengui before using print(self.List.AbsoluteContentSize.Y) self.ScrlFrame.CanvasSize =, 0, 0, self.List.AbsoluteContentSize.Y)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.