FlavoredProject.IVsUIHierarchy.GetCanonicalName 方法

获取唯一名称与在层次结构中的项。用于工作区持久性,例如确保窗口位置。

命名空间:  Microsoft.VisualStudio.Shell.Flavor
程序集:  Microsoft.VisualStudio.Shell.11.0(在 Microsoft.VisualStudio.Shell.11.0.dll 中)

语法

声明
Private Function GetCanonicalName ( _
    itemid As UInteger, _
    <OutAttribute> ByRef pbstrName As String _
) As Integer Implements IVsUIHierarchy.GetCanonicalName
int IVsUIHierarchy.GetCanonicalName(
    uint itemid,
    out string pbstrName
)

参数

  • pbstrName
    类型:System.String%
    [out] 项目的规范名称。

返回值

类型:System.Int32
如果方法成功,则返回 [F:Microsoft.VisualStudio.VSConstants.][S_OK]。如果失败,它会返回一个错误代码。

实现

IVsUIHierarchy.GetCanonicalName(UInt32, String%)

备注

此方法调用 GetCanonicalName

规范名称不会更改该环境的会话之间,但是,项 ID。使用此方法控制工作区持久性,例如确保窗口位置。

.NET Framework 安全性

请参见

参考

FlavoredProject 类

Microsoft.VisualStudio.Shell.Flavor 命名空间