IVsTrackProjectDocuments2.OnAfterRenameDirectories Method

This method is called by a project after a directory has been renamed in the project.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)

Syntax

'Declaration
Function OnAfterRenameDirectories ( _
    pProject As IVsProject, _
    cDirs As Integer, _
    rgszMkOldNames As String(), _
    rgszMkNewNames As String(), _
    rgFlags As VSRENAMEDIRECTORYFLAGS() _
) As Integer
int OnAfterRenameDirectories(
    IVsProject pProject,
    int cDirs,
    string[] rgszMkOldNames,
    string[] rgszMkNewNames,
    VSRENAMEDIRECTORYFLAGS[] rgFlags
)
int OnAfterRenameDirectories(
    [InAttribute] IVsProject^ pProject, 
    [InAttribute] int cDirs, 
    [InAttribute] array<String^>^ rgszMkOldNames, 
    [InAttribute] array<String^>^ rgszMkNewNames, 
    [InAttribute] array<VSRENAMEDIRECTORYFLAGS>^ rgFlags
)
abstract OnAfterRenameDirectories : 
        pProject:IVsProject * 
        cDirs:int * 
        rgszMkOldNames:string[] * 
        rgszMkNewNames:string[] * 
        rgFlags:VSRENAMEDIRECTORYFLAGS[] -> int
function OnAfterRenameDirectories(
    pProject : IVsProject, 
    cDirs : int, 
    rgszMkOldNames : String[], 
    rgszMkNewNames : String[], 
    rgFlags : VSRENAMEDIRECTORYFLAGS[]
) : int

Parameters

  • cDirs
    Type: System.Int32

    [in] Number of directories to rename.

  • rgszMkOldNames
    Type: array<System.String[]

    [in] Array of paths for the old names of the directories.

  • rgszMkNewNames
    Type: array<System.String[]

    [in] Array of paths for the new names of the directories.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From IVsTrackProjectDocuments2.idl

HRESULT IVsTrackProjectDocuments2::OnAfterRenameDirectories(
   [in] IVsProject *pProject,
   [in] int cDirs,
   [in, size_is(cDirs)] const LPCOLESTR rgszMkOldNames[],
   [in, size_is(cDirs)] const LPCOLESTR rgszMkNewNames[],
   [in, size_is(cDirs)] const VSRENAMEDIRECTORYFLAGS rgflags[]
);

The project calls this method after it has renamed a directory to notify the environment that the directory has been renamed.

Note

All directory calls are optional. However, if you call one of the OnQuery* directory methods, then you are required to call the corresponding OnAfter* directory method if the OnQuery* call was successful.

.NET Framework Security

See Also

Reference

IVsTrackProjectDocuments2 Interface

Microsoft.VisualStudio.Shell.Interop Namespace