Raised This Month: $ Target: $400
 0% 

File functions - Which to use


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
facuq
Junior Member
Join Date: Feb 2007
Old 02-09-2007 , 02:40   Re: File functions - Which to use
Reply With Quote #3

Great! Thanks for the speedy reply.

Another quick question: From what i've read, I assume the difference between fgets/fputs and read_file/write_file is that while the first ones have a c like behaviour, the write_file, because it offers "line operations", it "moves" the file everytime a line has its lenght modified, or a line is added somewhere other than the EOF, and read_file has to do a sequential search counting /n to reach a line number (hence the "expensiveness").

Ok then, since I need a fixed-size record file I was hoping i could use a function like C's fread, but i guess i'll have to abuse fgets.

Again, thank you for your help!

Last edited by facuq; 02-09-2007 at 17:38.
facuq is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 00:36.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode