I'm trying to produce a file using the commands OpenFile, AppendFile and CloseFile. But the file remains empty. I already checked that the CloseFile command was carried out, and that the variables in 
AppendFile "&[nomeFile]" &[ApplMod] &[RevSoft] &[Docum]
are correctly filled. What could be the reason?

AppendFile uses the names of the variables for the record fields, not direct values. Please write 
AppendFile "&[nomeFile]" ApplMod RevSoft Docum 
instead of
AppendFile "&[nomeFile]" &[ApplMod] &[RevSoft] &[Docum]