How many files can I open at once?

Windows specific forum
RichardL
Enthusiast
Enthusiast
Posts: 532
Joined: Sat Sep 11, 2004 11:54 am
Location: UK

How many files can I open at once?

Post by RichardL »

The subject lines says it all! Do Windoze or PB impose a limit?

I have a binary file of up to 64 MByte containing records from up to 50 measuring instruments. I want to extract the records for each instrument and write them into separate files. So:

I can scan my source file 'N' times and extract one individual instrument's readings; this requires just two files to be open at once. This is safe, but I suspect is slow.

OR:

I can scan the source file once and open a destination file for each instrument; closing them all at the end.

The reason I am a bit nervous about having too many files open at once is that there was a limit imposed in GFA BASIC (RIP old Friend) that may have been due to a feature of Windows... I don't know.
freak
PureBasic Team
PureBasic Team
Posts: 5940
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Post by freak »

There should be no limit to the number of possible open files.
quidquid Latine dictum sit altum videtur
RichardL
Enthusiast
Enthusiast
Posts: 532
Joined: Sat Sep 11, 2004 11:54 am
Location: UK

Post by RichardL »

Hi Freak,

Thanks,

I coded the data collation routine with just six instruments and it all works as expected. I'm now looking through the archives for some files with a large number of instruments to further test.
Post Reply