iDomo
iDomo

Reputation: 179

Read a chunk of a file using WINAPI's ReadFile or something similar?

Well, I'm working on a project, in which I'm handling potentially big files, that I can't load into ram all at once, so I'm going to treat them like a CHS hard drive, and grab the data one 0x800 byte chunk at a time.

My problem is, I cannot find any functions in the WINAPI that allow me to read the data from a file I've opened with CreateFile, starting at an offset.

And yes, it must be a WINAPI function, and no, I do not want to map the whole file into memory.

Thanks much, Bradley.

Upvotes: 1

Views: 1828

Answers (1)

Erti-Chris Eelmaa
Erti-Chris Eelmaa

Reputation: 26268

Use ReadFile with SetFilePointer

Upvotes: 2

Related Questions