This documentation is archived and is not being maintained.

IVsTrackProjectDocuments2.OnAfterAddFilesEx Method

This method is called by a project after files have been added to the project.

Namespace: Microsoft.VisualStudio.Shell.Interop
Assembly: Microsoft.VisualStudio.Shell.Interop (in microsoft.visualstudio.shell.interop.dll)

'Declaration
Function OnAfterAddFilesEx ( _
	<InAttribute> pProject As IVsProject, _
	<InAttribute> cFiles As Integer, _
	<InAttribute> rgpszMkDocuments As String(), _
	<InAttribute> rgFlags As VSADDFILEFLAGS() _
) As Integer
'Usage
Dim instance As IVsTrackProjectDocuments2
Dim pProject As IVsProject
Dim cFiles As Integer
Dim rgpszMkDocuments As String()
Dim rgFlags As VSADDFILEFLAGS()
Dim returnValue As Integer

returnValue = instance.OnAfterAddFilesEx(pProject, cFiles, rgpszMkDocuments, rgFlags)
int OnAfterAddFilesEx (
	/** @attribute InAttribute() */ IVsProject pProject, 
	/** @attribute InAttribute() */ int cFiles, 
	/** @attribute InAttribute() */ String[] rgpszMkDocuments, 
	/** @attribute InAttribute() */ VSADDFILEFLAGS[] rgFlags
)
function OnAfterAddFilesEx (
	pProject : IVsProject, 
	cFiles : int, 
	rgpszMkDocuments : String[], 
	rgFlags : VSADDFILEFLAGS[]
) : int

Parameters

pProject

[in] Project to which the files have been added.

cFiles

[in] Number of files that were added.

rgpszMkDocuments

[in] Array of paths for the files that were processed. This is the same size as cFiles.

rgFlags

[in] Array of flags. For a list of rgFlags values, see VSADDFILEFLAGS.

Return Value

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

COM Signature

From IVsTrackProjectDocuments2.idl

HRESULT IVsTrackProjectDocuments2::OnAfterAddFilesEx(
   [in] IVsProject *pProject,
   [in] int cFiles,
   [in, size_is(cFiles)] const LPCOLESTR rgpszMkDocuments[],
   [in, size_is(cFiles)] const VSADDFILEFLAGS rgFlags[]
);

The project must call this method after it has added files to notify the environment that the files have been added. Unlike OnAfterAddFiles, this method allows you to specify a unique flag for each file.

Show: