Re: Struct.Pack and Binary files

2008-01-28 Thread PurpleServerMonkey
On Jan 28, 1:48 pm, Grant Edwards <[EMAIL PROTECTED]> wrote: > On 2008-01-28, PurpleServerMonkey <[EMAIL PROTECTED]> wrote: > > > Having trouble working out an appropriate format string for packing a > > binary file. > > > The below is something I use for ASCII files but now I need something > > eq

Re: Struct.Pack and Binary files

2008-01-27 Thread Grant Edwards
On 2008-01-28, PurpleServerMonkey <[EMAIL PROTECTED]> wrote: > Having trouble working out an appropriate format string for packing a > binary file. > > The below is something I use for ASCII files but now I need something > equivalent for working with binary files i.e jpg, zips etc. > > fileHandle

Struct.Pack and Binary files

2008-01-27 Thread PurpleServerMonkey
Having trouble working out an appropriate format string for packing a binary file. The below is something I use for ASCII files but now I need something equivalent for working with binary files i.e jpg, zips etc. fileHandle = open("test.txt") while loop: fileBuffer = fileHandle.read(