On Aug 15, 3:33 am, Suresh Babu Kolla <[EMAIL PROTECTED]> wrote:
> Paul Carter wrote:
>
> > The problem is with how you are opening the file. You need to open in
> > binary mode if you wish to read your file unaltered. Also, file() is
> > preferred over open() these days I think. Use:
>
> > dfile =
> > Please don't top post.
>
> > The problem is with how you are opening the file. You need to open in
> > binary mode if you wish to read your file unaltered. Also, file() is
> > preferred over open() these days I think. Use:
>
> > dfile = file('test.csv', 'rb')
>
> From Python 2.5 library docume
Paul Carter wrote:
> On Aug 14, 1:32 pm, towers <[EMAIL PROTECTED]> wrote:
>> Thanks - your code works for me also.
>>
>> But I still get the issue when I read the file directly and add it to
>> the archive.
>>
>> Say if I:
>>
>> 1. Use the test.csv file created with your code - currently the line
On Aug 14, 1:32 pm, towers <[EMAIL PROTECTED]> wrote:
> Thanks - your code works for me also.
>
> But I still get the issue when I read the file directly and add it to
> the archive.
>
> Say if I:
>
> 1. Use the test.csv file created with your code - currently the line
> endings look good (viewed i
Thanks - your code works for me also.
But I still get the issue when I read the file directly and add it to
the archive.
Say if I:
1. Use the test.csv file created with your code - currently the line
endings look good (viewed in notepad on Win XP)
2. Run the following code:
# begin code
import
On Aug 14, 11:04 am, towers <[EMAIL PROTECTED]> wrote:
> Hi
>
> I'm probably doing something stupid but I've run into a problem
> whereby I'm trying to add a csv file to a zip archive - see example
> code below.
>
> The csv just has several rows with carriage return line feeds (CRLF).
>
> However a
Hi
I'm probably doing something stupid but I've run into a problem
whereby I'm trying to add a csv file to a zip archive - see example
code below.
The csv just has several rows with carriage return line feeds (CRLF).
However after adding it to an archive and then decompressing the line
endings