The Parent property of Player is locked, current parent: NULL

Hey, as the title states, this is my error. Not sure why because this code has worked before, but:
(This code is in a .activated statement for a a textbutton)

		for i,v in pairs(game.Players:GetPlayers()) do
			local RABC = RAB:clone()
			RAB.Name = v.Name
			RAB.Text = v.Name
			RAB.Parent = script.Parent.Parent.Admin.PlayerList
				if SelPlr[1] == nil then
					table.insert(SelPlr, RAB.Text)
					Selected.Text = "Selected: " .. SelPlr[1]
					table.remove(SelPlr, 1)
					table.insert(SelPlr, RAB.Text)
					Selected.Text = "Selected: " .. SelPlr[1]

What line is erroring?
What is RAB?
What is SelPlr?

That’s because the “Parent” of “Players” is the game itself. You cannot access anything beyond Players similar to how you cannot access anything beyond workspace.

I’m not sure where your script is located but I’m suspecting that you are using one too many “Parents” on this line.

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