Gui won't appear after equipping tool

My gui won’t appear after equipping a tool, I’ve tried to make it so the script prints a message when equipped, and it got printed successfully. I’ve also tried to make it so the script prints the Frame’s name when equipped, which also got printed successfully. Are there any mistakes in this script?

The script is a localscript located inside the tool.
“plr” is

game.Players.LocalPlayer

I figured it out by myself, I replaced

A10Frame.Visible = true

with

plr.PlayerGui.A10.Frame.Visible = true

and it worked.