Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

What does ' attempt to concatenate Instance with string' mean?

Im getting this error:Workspace.Script1.Script2:179: attempt to concatenate Instance with string Can you please explain to me what it means? Thanks for your time!

1 answer

✓ Accepted answer

Well the error itself means that you were trying to concat an object with a string.

Example of what could have been in your code

local ErrorLine = script.Parent.." bop"

You're concating an instance object with a string. So you're supposed to do something like this instead

local ErrorLine = tostring(script.Parent).." bop"
--or
local ErrorLine = script.Parent.Name.." bop"

Note: There are other ways to concat and I just chose that method since it's more visual.

2 comments

0

Awesome Thanks a lot!!! You helped me fix it Have a nice day!

0

No problem you too :)

This discussion is preserved as it was. New answers, comments, and votes are closed.