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

Help with image and strings?

selectedimage.Value = v.Image.Image

20:32:08.063 - Players.Player.PlayerGui.ScreenGui.ShopFrame.ShopScript:70: bad argument #3 to 'Value' (string expected, got nil) Shouldn't the Image already be a string??

2 comments

0

Perhaps you should give us extra context to the values.

0

You could try setting a variable to tostring, so String = tostring(v.Image.Image), then selectimage.Value = String

1 answer

✓ Accepted answer

This is occuring because you're trying to place a nil value into selectedimage.Value. This means v.Image.Image is returning nil instead of the string you want. Check to see if v.Image.Image is the correct way to get the string you want.

2 comments

0

Your answer made no sense.. v.Image.Image has a string value, which is the items image. And selectedimage.Value is a stringvalue

0

Well, that's what I'd think, too, but the error message says otherwise.

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