Net message not sending as intended

When I run this command

cl_init


concommand.Add("testnet3", function()
RunConsoleCommand("printmodel")
net.Receive( "test", function()

reads = net.ReadString()
	print(reads)
end )



end)

init


	concommand.Add("printmodel", function(ply)
	npcmodel = sql.QueryValue( "SELECT model from pkmn12 WHERE SteamID = '".. ply:SteamID() .."' " )
print(npcmodel)

util.AddNetworkString("test")
net.Start("test")
net.WriteString( npcmodel)
net.Send(ply)

	end)

It will return models/player/kleiner.mdl but only server side.
If I run it again it will return models/player/kleiner.mdl server side and client side. I want to be able to run it just once and for models/player/kleiner.mdl to show up clientside and server side. Is there a work around or am I doing something wrong?

You should read up on this, You probably didn’t ‘register’ the network string.

Thanks, turns out I had to register the network string outside of the function.