Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!m.cs.uiuc.edu!vela!rdthomps From: rdthomps@vela.acs.oakland.edu (Robert D. Thompson) Newsgroups: comp.windows.ms.programmer Subject: *** USING _llseek WITH LARGE FILES *** |(8> HELP <8)| Message-ID: <5935@vela.acs.oakland.edu> Date: 17 Apr 91 18:56:18 GMT Reply-To: rdthomps@vela.acs.oakland.edu (Robert D. Thompson) Distribution: world Organization: Oakland University, Rochester MI Lines: 35 Someone, According to the SDK, I should be able to open a file, hFile = _lopen("myfile.txt", OF_READ); Notice that this is a text file, not a binary one. Then, I should be able to "randomly" access the end of the file, _llseek(hFile, (long int)newPosition, 2); The "2", of course, is the iOrigin specifying that the newPosition is an offset from the END OF THE FILE. But this never works. The return value of _llseek (the new file position) is always a large negative number. How can I get around this? This file is a very large file. I thought I remember reading something about files larger than 64k and how one must get around this. I would appreciate anyones help. Thanks. --- Robert rdthomps@vela.acs.oakland.edu