lock file
-
hi all i m working on a project where i need to lock file so that it can not be accessed again till certain conditions are met. the "LockFile ()" comd of VC++ deals with locking only a few selected bytes, is there any other such comd or method to achive my requirement???? please guide thanks
-
hi all i m working on a project where i need to lock file so that it can not be accessed again till certain conditions are met. the "LockFile ()" comd of VC++ deals with locking only a few selected bytes, is there any other such comd or method to achive my requirement???? please guide thanks
if you run this code what happens?
HANDLE handle; DWORD m\_Pos,m\_NumberofFile=0; handle=CreateFile(\_T("e:\\\\1.bmp"),
GENERIC_READ,0,NULL,OPEN_EXISTING,FILE_ATTRIBUTE_NORMAL,NULL);
dwPos = SetFilePointer(handle, 0, NULL, FILE_END);
LockFile(handle, m_Pos, 0, m_NumberofFile, 0);