[newbe] Copy Files lazarus / 9-Editor ---------------------------------------------------------------------- blyleven · 2007-05-01 07:54 Hi all, I'm sorry I'm new to  pascal, shame on me. I want to create a program that moves a mp3 file to a different folder, with one click on a button. I created a "program" with the button: Code: [Select] procedure TIMPORT.Button1Click(Sender: TObject); begin      ShowMessage('Done!'); end; The folder of mp3 files is: "K:\mp3\" The folder where the files should be copied to is: "K:\music\" Can anybody tell me how to do this? Thank you very much ---------------------------------------------------------------------- antonio · 2007-05-01 09:15 You could do it by Windows API call Movefile. See at http://msdn2.microsoft.com/en-us/library/aa383749.aspx ---------------------------------------------------------------------- theo · 2007-05-01 10:15 CopyFile is portable: http://www.freepascal.org/docs- html/lcl/fileutil/copyfile.html See also here: http://www.freepascal.org/docs-html/rtl/sysutils/filenameroutines.html http://www.freepascal.org/docs-html/lcl/fileutil/index-5.html