Invalid set index 'icon' (on base: 'null instance') with value of type 'StreamTexture'.

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By myihd

I’m getting an error every time i write

if pl == 1:
	$Button.icon = load("res://icons/+=.png")
else:
	$Button.icon = load("res://icons/+.png")

the error is:
Invalid set index ‘icon’ (on base: ‘null instance’) with value of type ‘StreamTexture’.
pls help

:bust_in_silhouette: Reply From: exuin

If you see “null instance” it means that your node path is most likely wrong. Check your node hierarchy and capitalization.