IVsTrackProjectDocumentsEvents3::HandsOffFiles Method (UInt32, Int32, array<String^>^)
Accesses a specified set of files and asks all implementers of this method to release any locks that may exist on those files.
Assembly: Microsoft.VisualStudio.Shell.Interop.8.0 (in Microsoft.VisualStudio.Shell.Interop.8.0.dll)
int HandsOffFiles( unsigned int grfRequiredAccess, int cFiles, array<String^>^ rgpszMkDocuments )
Parameters
- grfRequiredAccess
-
Type:
System::UInt32
[in] A value from the __HANDSOFFMODE enumeration, indicating the type of access requested. This can be used to optimize the locks that actually need to be released.
- cFiles
-
Type:
System::Int32
[in] The number of files in the rgpszMkDocuments array.
- rgpszMkDocuments
-
Type:
array<System::String^>^
[in] If there are any locks on this array of file names, the caller wants them to be released.
Return Value
Type: System::Int32If the method succeeds, it returns S_OK. If it fails, it returns an error code.
From ivstrackprojectdocumentsevents80.idl
HRESULT HandsOffFiles( [in] HANDSOFFMODE grfRequiredAccess, [in] int cFiles, [in, size_is(cFiles)] const LPCOLESTR rgpszMkDocuments[] );
This method is called as a result of a call to the HandsOffFiles method.
This method is typically called just before a batch process on a collection of files is performed. This method should release any locks held on the files before returning. If this method returns an error code, the project may still continue with the batch process. This method should be implemented to properly release any locks as quickly as possible.