protected Boolean FileIsLocked ( IOException oIOException ) { Debug.Assert(oIOException != null); AssertValid(); Int32 iErrorCode = Marshal.GetHRForException(oIOException) & ( (1 << 16) - 1 ); return (iErrorCode == 32 || iErrorCode == 33); }