IVsPersistDocData.RenameDocData(UInt32, IVsHierarchy, UInt32, String) Method

Definition

Renames the document data.

public:
 int RenameDocData(System::UInt32 grfAttribs, Microsoft::VisualStudio::Shell::Interop::IVsHierarchy ^ pHierNew, System::UInt32 itemidNew, System::String ^ pszMkDocumentNew);
public:
 int RenameDocData(unsigned int grfAttribs, Microsoft::VisualStudio::Shell::Interop::IVsHierarchy ^ pHierNew, unsigned int itemidNew, Platform::String ^ pszMkDocumentNew);
int RenameDocData(unsigned int grfAttribs, Microsoft::VisualStudio::Shell::Interop::IVsHierarchy const & pHierNew, unsigned int itemidNew, std::wstring const & pszMkDocumentNew);
public int RenameDocData (uint grfAttribs, Microsoft.VisualStudio.Shell.Interop.IVsHierarchy pHierNew, uint itemidNew, string pszMkDocumentNew);
abstract member RenameDocData : uint32 * Microsoft.VisualStudio.Shell.Interop.IVsHierarchy * uint32 * string -> int
Public Function RenameDocData (grfAttribs As UInteger, pHierNew As IVsHierarchy, itemidNew As UInteger, pszMkDocumentNew As String) As Integer

Parameters

grfAttribs
UInt32

[in] File attribute of the document data to be renamed. See the data type __VSRDTATTRIB.

pHierNew
IVsHierarchy

[in] Pointer to the IVsHierarchy interface of the document being renamed.

itemidNew
UInt32

[in] Item identifier of the document being renamed. See the data type VSITEMID.

pszMkDocumentNew
String

[in] Path to the document being renamed.

Returns

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

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsPersistDocData::RenameDocData(  
   [in] VSRDTATTRIB grfAttribs,  
   [in] IVsHierarchy *pHierNew,  
   [in] VSITEMID itemidNew,  
   [in] LPCOLESTR pszMkDocumentNew  
);  

This method can also transfer ownership of the document data from one hierarchy to another.

Applies to