SaveBufAs (hbuf, filename)

Saves a file buffer a different file name. Hbuf is the buffer handle. Filename is the name of the new file.