<pre>on saveFile fileContent,filePath  toComputer  --------------------------------------------------------------------------  if filePath is empty or filePath is "filePath" then    if there is a fld "Header" then      put fld "Header" into defaultFileName      ask file "Nom du fichier ?" with defaultFileName    else      ask file "Nom du fichier ?"    end if    if it is empty or the result is "cancel" then exit saveFile    put it into filePath  end if  --------------------------------------------------------------------------  set cursor to watch  if fileContent is empty and there is a fld "text"  then writeFile fld "text",filePath  else writeFile fld fileContent,filePath  --------------------------------------------------------------------------  put getFileName(filePath) into fld "Header"end saveFile</pre>