Hello, i am trying to create this script that gets all the objects in a folder and creates a text label for everyone of them in a ScrollingGui, The script sizes it as should and positions it as should but stuff like the text is invisible and the background is invisible.
Here is my code:
script.Parent.MouseButton1Down:Connect(function() local list = script.Parent.Parent.Parent.Folder for i,v in pairs(list:GetChildren()) do local label = Instance.new("TextLabel") label.Name = tostring(i) label.Text = v.Name label.BackgroundColor3 = Color3.new(67, 67, 67) label.BorderSizePixel = 0 label.TextColor3 = Color3.new(255, 255, 255) label.TextSize = 18 label.TextXAlignment = Enum.TextXAlignment.Left label.TextYAlignment = Enum.TextYAlignment.Center label.Size = UDim2.new(0, 251, 0, 31) label.ZIndex = 10 if i == 1 then label.Position = UDim2.new(0, 0, 0, 0) else local lastlabel = script.Parent.Parent.ListContent:FindFirstChild(tostring(i - 1)) label.Position = UDim2.new(0, 0, 0, lastlabel.Position.X.Offset + lastlabel.Size.Y.Offset) end label.Parent = script.Parent.Parent.ListContent end end)
If enyone can help me that would be great!
~you need to tell it what to put as the text.