I'm new to programming.

My program ask the name of user
ask "what's your name?"
put it into tName
put "tName" into a field "score" put (name & cr) into field "score"
then my program produces a file using the command
put field "score" into URL ( "file:tname")
but how can I produce a file with the name of the user (using the variable "tName")? Because the users are a lot, and I don't want that the file is overwritten
thanks