that's final code that work for sure. But you have to remember to put player name uppercase before check lenght and if the name have letters or numbers.
if playerscore > highscore(10)
sprite record1 ,5,40,12
sprite playern ,5,100,13
sprite alphabet1 ,5,300,14
input " ",(playername$)
playername$ = upper$ (playername$)
delete sprite record1
delete sprite playern
delete sprite alphabet1
endif
while len(playername$) < 3 or len(playername$) > 6
sprite alphabet2,0,0,15
wait key
cls
set cursor 20,200
delete sprite alphabet2
wait 100
sprite record1 ,5,40,12
sprite playern ,5,100,13
sprite alphabet1 ,5,300,14
input " ",playername$
playername$ = upper$(playername$)
delete sprite record1
delete sprite playern
delete sprite alphabet1
endwhile
if len(playername$) >= 3 or len(playername$) <=6
for x = 1 to len(playername$)
while asc(mid$(playername$,x)) <65 or asc(mid$(playername$,x)) > 90
sprite alphabet2,0,0,15
wait key
cls
set cursor 20,200
delete sprite alphabet2
wait 100
sprite record1 ,5,40,12
sprite playern ,5,100,13
sprite alphabet1 ,5,300,14
input " ",playername$
playername$ = upper$(playername$)
delete sprite record1
delete sprite playern
delete sprite alphabet1
endwhile
next x
endif
Try be yourself.