created a screen GUI and when you press the clear button it's supposed to clear it but nothing happens, could someone help me?
for i, v in pairs(workspace.Important.OrderScreen.main.Orders:GetChildren()) do
if v.Name ~= "UIListLayout" then
v.ClearOrder.Activated:connect(function()
orders[v.Name] = false
v.Visible = false
v.OrderText.Text = ''
v.TableText.Text = ''
end)
end
end

5 comments
R u doing it in starter gui and not the player gui?
It's a ScreenGui on a TV
the for loop only runs once, so that means you literally have no time to press the button when the loop runs
That didn't fix it, because once you call it it actively listens for it to be activated and should run the code once it is.
cant you use gui.mousebutton1click?