Hi,

Thanks for the reply, yes this is certainly an option and one I will have to investigate if I cannot find a quicker solution to my problem. However this code is very complicated and it would take me a lot of time to extract it and modularise it so I could re-write it without breaking it entirely.

I was more hoping to get a solution for the more immediate problem of why fgets is so slow when using in conjunction with fseek.

Does anyone have any ideas?

Cheers
Dan