I have a inventory gui that I am making so you can move to "Sort" your inventory. It will not work, It always errors. Here is the script (Normal script inside text button):
local MovingInventory = script.Parent.Parent.Parent.Parent.Parent.MovingInventory
local SlotMoving = script.Parent.Parent.Parent.Parent.Parent.MovingInventory
script.Parent.MouseButton1Click:Connect(function()
if MovingInventory.Value == false then
MovingInventory.Value = true
SlotMoving.Value = script.Parent.Name
elseif MovingInventory.Value == true then
MovingInventory.Value = false
game.ReplicatedStorage.Values:WaitForChild("Item").Value = script.Parent.Parent:FindFirstChild(SlotMoving.Value).Item.Value
game.ReplicatedStorage.Values:WaitForChild("Amount").Value = script.Parent.Parent:FindFirstChild(SlotMoving.Value).Amount.Value
script.Parent.Item.Value = script.Parent.Parent:FindFirstChild(SlotMoving.Value).Item.Value
script.Parent.Amount.Value = script.Parent.Parent:FindFirstChild(SlotMoving.Value).Amount.Value
script.Parent.Parent:FindFirstChild(SlotMoving.Value).Item.Value = game.ReplicatedStorage.Values.Item.Value
script.Parent.Parent:FindFirstChild(SlotMoving.Value).Amount.Value = game.ReplicatedStorage.Values.Amount.Value
end
end)
Thanks!

2 comments
(sorry if it is sloppy, this is a repost since nobody answered the original question within a month.)
Whats the error and on what line it occurs?