Compartilhar via


IVsCfgProviderEvents.OnCfgNameRenamed Method

Notifies the environment when a configuration name has been renamed.

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

Syntax

'Declaration
Function OnCfgNameRenamed ( _
    pszOldName As String, _
    lszNewName As String _
) As Integer
int OnCfgNameRenamed(
    string pszOldName,
    string lszNewName
)
int OnCfgNameRenamed(
    [InAttribute] String^ pszOldName, 
    [InAttribute] String^ lszNewName
)
abstract OnCfgNameRenamed : 
        pszOldName:string * 
        lszNewName:string -> int
function OnCfgNameRenamed(
    pszOldName : String, 
    lszNewName : String
) : int

Parameters

  • pszOldName
    Type: String

    [in] Pointer to the original name of the configuration.

  • lszNewName
    Type: String

    [in] Pointer to the new name of the configuration.

Return Value

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

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsCfgProviderEvents::OnCfgNameRenamed(
   [in] LPCOLESTR pszOldName,
   [in] LPCOLESTR lszNewName
);

If the configuration object renames configurations with a clone operation following by a delete operation, it will generate add and delete events rather than a rename event. That is, OnCfgNameAdded will be called following OnCfgNameDeleted instead of this method.

.NET Framework Security

See Also

Reference

IVsCfgProviderEvents Interface

Microsoft.VisualStudio.Shell.Interop Namespace