Category : Pascal Source Code
Archive   : FCOPY4.ZIP
Filename : FCOPY.PAS

 
Output of file : FCOPY.PAS contained in archive : FCOPY4.ZIP
program FCopy;
{ FCopy - A demo program for the FileCopy unit
version 1.1 4/20/88
by Richard S. Sadowsky

Released to the public domain

USAGE:

FCOPY source dest
copies file specified by source into file specified by dest. Souce and dest
MUST be complete file names (with path if desired).
In other words, this is unacceptable:
FCOPY FCOPY.PAS A:
Instead, you would do:
FCOPY FCOPY.PAS A:FCOPY.PAS

See FILECOPY.PAS for source to the filecopy unit.
}
uses FileCopy;

var
ErrorCode : Word;

begin
if ParamCount < 2 then begin { make sure user gave us two file names }
WriteLn('FCOPY SourcePath DestPath'); { show syntax }
Halt(1) { and abort }
end;

ErrorCode := File_Copy(ParamStr(1),ParamStr(2),$FFFF); { copy 'em }
{ use as big a copy buffer as possible }

if ErrorCode = 0 then
WriteLn('Copied!') { WE MADE IT! }
else
WriteLn('Error #',ErrorCode); { whoops }
end.


  3 Responses to “Category : Pascal Source Code
Archive   : FCOPY4.ZIP
Filename : FCOPY.PAS

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/