Re: INI file and NUM files
Hi Asm,
Looks like OP will have to divine this format on their own. You're right
though, CFile would work if they knew the structure of the data. I am not a
big fan of storing binary data unless there is some other purpose (like a
wav file). If it's just for program data I'd likely convert it to something
readable before writing it out (like XML). The problem with binary data
files is that it's difficult to modify the format for future improvements.
Tom
"MrAsm" <mrasm@usa.com> wrote in message
news:brvv531ahpcl802u4quoo249jidmhj7893@4ax.com...
On Thu, 31 May 2007 20:16:01 -0700, reen_haz
<reenhaz@discussions.microsoft.com> wrote:
NUM file is a file that stores binary data...
We don't know how this binary data is structured...
You might consider the CFile code I posted in this thread.
If you want to store several instances of the same data structure, you
might write a number that stores the count of instances, and then all
the instances, e.g.
<count>
<data1>
<data2>
...
<dataN>
So when you read data back, you can read the count value, resize an
array with this count value, and then do a for loop to read all data
instances in the array.
MrAsm