OK.
ive got a nice little function, perfect, but I can`t get ios:app to work in binary or text mode. ios::out works tho.
I`ve copied from book, looked it up, tried to examine old C code to link externally, and i come up with a null.
So then, how would you go about making a function that appends to a file if the files already there and if its not there, creates it and appends to it ?
My personal guess is to get the files size, put a pointer to the end of the file, and write to the eof...
I don`t understand the implementation of pointer very well, neither do i know asm, thats why i`m asking. For OS, it needs to run in W9x`s DOS32 port.
~V''lion
I came, I saw, I got programmers block.
~V''lion
~V'lionBugle4d
You probably just had a couple of typos, but in case you didn''t, you should know it''s ios::app...just like ios::out...anyway, sorry if that didn''t help.
Chris
it''s my understanding ios::app automatically writes to the end of the file ( meaning it starts there, and you don''t have to find it ) I could be wrong, though.
Yes. It contains some kin of pointer to the eof that is updated automatically.
I don`t have typos, I can run ios::out on it perfectly.
Sorry about that theorem. :-/
Unfortanly, what my implementation of ios::app does is create a new file and write nothing, or if it already exsists, does nothing.
My compiler is VC++5
So....how would I go about writing a append func ?
I came, I saw, I got programmers block.
~V''lion
I don`t have typos, I can run ios::out on it perfectly.
Sorry about that theorem. :-/
Unfortanly, what my implementation of ios::app does is create a new file and write nothing, or if it already exsists, does nothing.
My compiler is VC++5
So....how would I go about writing a append func ?
I came, I saw, I got programmers block.
~V''lion
~V'lionBugle4d
Post the exact code you used, there''s a typo in there somewhere ''cause it works perfectly over here.
You have to be careful mixing flags - make sure you''re not doing that.
~ Mad Keith ~
**SoftwareMode**
You have to be careful mixing flags - make sure you''re not doing that.
~ Mad Keith ~
**SoftwareMode**
It's only funny 'till someone gets hurt.And then it's just hilarious.Unless it's you.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement