StringValue

Hold a piece of text in the tree: a name, a greeting, the folder a tool works in.

Value is a string, empty by default, and assigning a number errors instead of converting it. Read it as script.Parent.Settings.WorkFolder.Value; each change fires Changed with the new text.

Made with Instance.new("StringValue") or Clone().

Example

Change some textShotScript
-- A StringValue holds text, and Changed fires only when it really changes. Settings.Title is one, saved as Notes.
local title = root.Settings.Title
title.Changed:Connect(function(text : string)
	print("Title is now " .. text)
end)
print("Title starts as " .. title.Value)
title.Value = "Notes"
title.Value = "Shop"
print("a new StringValue is empty: " .. tostring(Instance.new("StringValue").Value == ""))
What it printedOutput
Title starts as Notes
Title is now Shop
a new StringValue is empty: true

Properties

NameTypeDefaultDescription
Valuestring""The text it holds; assigning a number errors instead of converting it, and each change fires Changed with the new text.
From ShotInstance 33