Aracılığıyla paylaş


IVsRunningDocumentTable.RenameDocument Yöntem (String, String, IntPtr, UInt32)

 

Yeniden adlandırır ve/veya belge sahipliğini değiştirir.

Ad Alanı:   Microsoft.VisualStudio.Shell.Interop
Derleme:  Microsoft.VisualStudio.Shell.Interop (Microsoft.VisualStudio.Shell.Interop.dll içinde)

Sözdizimi

int RenameDocument(
    string pszMkDocumentOld,
    string pszMkDocumentNew,
    IntPtr pHier,
    uint itemidNew
)
int RenameDocument(
    String^ pszMkDocumentOld,
    String^ pszMkDocumentNew,
    IntPtr pHier,
    unsigned int itemidNew
)
abstract RenameDocument : 
        pszMkDocumentOld:string *
        pszMkDocumentNew:string *
        pHier:nativeint *
        itemidNew:uint32 -> int
Function RenameDocument (
    pszMkDocumentOld As String,
    pszMkDocumentNew As String,
    pHier As IntPtr,
    itemidNew As UInteger
) As Integer

Parametreler

  • pHier
    Type: System.IntPtr

    [in] IVsHierarchy Sahipliğini için arabirim. Kullanım HIERARCHY_DONTCHANGE ise, sahipliğini değiştirme değil.

Dönüş Değeri

Type: System.Int32

Yöntem başarılı olursa, döndürür S_OK. Başarısız olursa, bir hata kodu döndürür.

Notlar

COM imza

Vsshell.idl:

HRESULT IVsRunningDocumentTable::RenameDocument(
   [in] LPCOLESTR     pszMkDocumentOld,
   [in] LPCOLESTR     pszMkDocumentNew,
   [in] IVsHierarchy *pHier,
   [in] VSITEMID      itemidNew
);

Proje hiyerarşisi için belge sahipliğini aktarmak ve yeni bir belge vermek için bu yöntemi çağırmanız gerekir itemid Proje içinde.

Ayrıca bkz.

IVsRunningDocumentTable Arabirim
Microsoft.VisualStudio.Shell.Interop Ad Alanı

Başa dön