--- local script----
script.Parent.MouseButton1Click:connect(function()
game.ReplicatedStorage.RemoteEvent:FireServer(script.Parent.CName, script.Parent.CValue)
end)
--Server--
game.ReplicatedStorage.RemoveEvent.OnServerEvent:connect(function(player, CName, CValue)
game.Workspace.CNameW = CName.Value
game.Workspace.CValueW = CValue.Value
end)
ERROR: attempt to index local 'CName' (a nil value)

2 comments
You could try sending the values in the local script
but exploiters will be able to change that i dont want that.