Please help me. I search it in google. and i found 2 ways.
1.Source
local script = Instance.new("Script",workspace)
script.Source = 'print("Hello world!")'
But this isn't working anymore.
2.loadstring
local script = Instance.new("Script",workspace) --why did he Instance a script? ( EteraW )
code.Value = 'print("Hello world!")'
loadstring(code.Value)()
This look like to work. But I don't know how to stop the script.
script:Destroy() doesn't stop the script.
Please help. I'm confused now!

3 comments
why would you need to do this? just clone the script for replicated or storage.
I want player to put their script in text box and run the script
It's impossible to do so. Cloning a script copies its code over, but attempting to write to it from another script is not possible.