> This should do it:
>
> bos = createObject("java", "java.io.ByteArrayOutputStream").init();
> bos.write(binary_stuff,0,len(binary_stuff));
> bos.write(ender,0,len(ender));
> New_binary = bos.tobytearray();
> bos.close();
>
> Probably a better way with the fileinputstream but I already had this
>
This should do it:
bos = createObject("java", "java.io.ByteArrayOutputStream").init();
bos.write(binary_stuff,0,len(binary_stuff));
bos.write(ender,0,len(ender));
New_binary = bos.tobytearray();
bos.close();
Probably a better way with the fileinputstream but I already had this
code so I figured I
> That will only work if the first file has a size that is a
> multiple of 3 bytes.
Thanks for the info Jochem! I guess that it's only doable using some
CF add-ons like CFOBJECT then?
--
Marc
[Todays Threads]
[This Message]
[Subscription]
[Fast Unsubscribe]
[User Settings]
[Donations an
It occurs to me that you could use the system to concatenate two files,
then read them as binary.
ie you could "copy file1+file2 file3 /b" and then read file3.
--Ben
Neculai Macarie wrote:
> Hi!
>
> Is there a way to concatenate 2 binary variables (that contain 2 files):
&
Marc Campeau wrote:
>>Is there a way to concatenate 2 binary variables (that contain 2 files):
>>
>>
> Otherwise, maybe you can convert both files to Base64, do the
> concatenation and then reconvert back to binary...
That will only work if the first file has a size
> Is there a way to concatenate 2 binary variables (that contain 2 files):
>
>
You'll probably want to use some Java (look at
java.io.fileInputStream) to do that since CFFILE deals mostly with
text files, especially if you want to write the results to a file.
Otherwise, maybe y
Hi!
Is there a way to concatenate 2 binary variables (that contain 2 files):
I want to have a single variable, something like this:
Thanks,
[Todays Threads]
[This Message]
[Subscription]
[Fast Unsubscribe]
[User Settings]
[Donations and Support]
7 matches
Mail list logo