Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Replacement for COPY filea + fileb
Message
 
 
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00523508
Message ID:
00523520
Views:
10
>Hi,
>
>I appreciate that this may not be a pure VFP question.
>
>I would like to be able to combine 2 files (specifically a PCL font in the same way that you used be able to in DOS with COPY filea + fileb filec. Is there a simple way of doing this maybe with the WINAPI.
>
>I am reluctant to use FOPEN(), FREAD(), FWRITE etc as some of these files are in excess of 250K, which would mean having to read in and write out 64K or less chunks at a time ( am I right in thinking that this is the max size for a variable in VFP). I'd prefer not to do it this way if there is a simpler way
>
>Thanks
>
>
>Simon Horne
Simon,

The FREAD(), FWRITE buffer size is limited to 64Kb but string size limit is 16Mb. You can use Filetostr and Strtofile to combine files
=Strtofile( Filetostr("File1.txt") + Filetostr("File2.txt"), "File3.txt")
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform