I don't know why it don't work
local GameIDType = game.StarterGui.ScreenGui.Frame.TextBox.Text
local TextButton = game.StarterGui.ScreenGui.Frame.TextButton
local TeleportService = game:GetService("TeleportService")
TextButton.MouseButton1Click:Connect(function(player)
TeleportService:Teleport(GameIDType, player)
end)