_lseek
<io.h>,_lseek returns the offset, in bytes, of the new position from the beginning of the file. _lseeki64 returns the offset in a 64-bit integer.
例:
/* Find current position: */
pos = _lseek( fh, 0L, SEEK_CUR );
if( pos == -1L )
perror( "_lseek to current position failed" );
else
printf( "Position for current position seek = %ld\n", pos );
fwrite ,wrtie,writefile的关系
Fwrite是C库函数,write是Linux系统API函数,writefile是windows系统API函数。
宽字节
保存到文件
fwprintf(fp,L"%d\r\n",100);