| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
| |||
| |||
| i have to make 2 programs: a program that converts .exe or .dll or .zip etc. into text file and a program that reads same text file and writes same binary file back. example data.exe->data.txt- >(transfer)->data.txt->data.exe the final text file can look like 4d 5a 90 00 etc. or 1100010011110 etc. or À¾Bÿ¾@e@ etc. or ascii(021) ascii(019) ascii(077) ascii(111), i dont care. why i need it: else program transfers files from a location to another like email atachments but only accepts text files. i expect that on the other side, after conversion, the .exe file or .zip file etc. will work. i found it very difficult reading binary files with blockread and how does it looks what it reads? any help or explaining would be much apreciated. thank you. |
|
#2
| |||
| |||
| On 2008-05-29, radu <lungu.radu@gmail.com> wrote: > i have to make 2 programs: a program that converts .exe or .dll > or .zip etc. into text file and a program that reads same text file > and writes same binary file back. example data.exe->data.txt- >>(transfer)->data.txt->data.exe > the final text file can look like 4d 5a 90 00 etc. or 1100010011110 > etc. or À¾Bÿ¾@e@ etc. or ascii(021) ascii(019) ascii(077) > ascii(111), i dont care. These have existed for aeons, search for uuencode/uudecode or mime/unmime. > i found it very difficult reading binary files with blockread and how > does it looks what it reads? It doesn't. It reads binary, IOW it just looks up the address in memory of whatever variable you pass, and starts banging <count> bytes into it. And it doesn't care if it fits. |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.