I\'m trying to base64 encode a huge input file and end up with an text output file, and I\'m trying to find out whether it\'s possible to encode the input file bit-by-bit, o
Hmmm, if you wrote the base64 conversion yourself you should have noticed the obvious thing: each sequence of 3 octets is represented by 4 characters in base64.
So you can split the base64 data at every multiple of four characters, and it will be possible to convert these chunks back to their original bits.
I don't know how character files and byte files are handled on an AS/400, but if it has both concepts, this should be very easy.
If you can answer all these questions, what exact difficulties do you have left?