I can't find my script error

I can’t find my script error

local function UpDateGui ()
for p = 1,Number do
	local Clone = script.Sample:Clone()
	Clone.Name = "Stage"..p
	Clone.Stage.Text = "Stage"..p
	if StageSave:Get(1) <= p then
		Clone.ButtonFrame.Visible  = true
		Clone.LockFrame.Visible = false
	end	
	Clone.Parent  = script.Parent.Frame.Frame.ScrollingFrame
	ScrollingFrame.CanvasSize = UDim2.new(0,0,(0.1)*p,0)
    end
    end

in the case above, only Stage1 was supposed to have the "GO"

What is “Number” defined as? What does the output say? It looks like you have some things in your script that might need fixing we don’t know of. Also I believe Get() can’t be used in scripts as said in this article.

Change

if StageSave:Get(1) <= p then

to

if StageSave:Get(1) >= p then

You can’t use the selection Get() in a script as said in the article I have provided above

This member cannot be used in scripts, but is usable in the command bar and plugins.

Thanks. 30characterrrrrrrrrrrr

1 Like

This is his own method, it’s not from the selection service.

“Get ()” can be used in this case because I’m using it to retrieve a value from DataStore2

ahh, sorry about that didn’t realize.

okay. 30characterrrrrrrrrrrrrr