How to open a file in binary mode and write it back in text mode
Thaks
Printable View
How to open a file in binary mode and write it back in text mode
Thaks
hi
i am not getting your problem..
but if you want to open file in binary mode then us CFile::typeBinary mode to open the file.
if this doesnot solves the problem then please specify the problem in detail
dhani99
Hi, I am trying to read a gif file in binary mode and want to write that file in text mode.
Is this the same question as How to open a file in binary mode?? That question is very strange and probably it is not possible to do what you are asking.
If you are not using MFC then in this forum you need to say so.
no i am not using MFC
You don't want to write a gif file in text mode. Text mode does two things as I understand it (and neither apply to GIF files):
1. it handles the EOF character gracefully
2. it converts carriage return–linefeed to linefeeds on input and back to carriage return–linefeed on output.
You do NOT want either of this things to happen in a GIF file.