I'm trying to make a part that you have to insert an answer into. I added a ScreenGUI to starterGUI, and added this localscript to open it when you click on the script's parent.
local function onMC(playerwhoclicked)
playerwhoclicked.PlayerGui.submit.TextBox.Visible = true
playerwhoclicked.PlayerGui.submit.TextButton.Visible = true
end
script.Parent.ClickDetector.MouseClick:connect(onMC)
The problem is, the script doesn't open anything. Also, none of the errors in console link to the script when clicked on. Keep in mind, I don't know anything about localscripts other than that they are scripts that are local.

2 comments
Is the script located in a part or in a gui and is the script a local script or server script.
It's a local script and of course it's in a part, as he mentioned in his question.