使用枚举指定编辑器,打开指定的文档。
命名空间: Microsoft.VisualStudio.Shell
程序集: Microsoft.VisualStudio.Shell.11.0(在 Microsoft.VisualStudio.Shell.11.0.dll 中)
语法
声明
Public Shared Function OpenDocumentWithSpecificEditor ( _
provider As IServiceProvider, _
fullPath As String, _
editorType As Guid, _
logicalView As Guid _
) As IVsWindowFrame
public static IVsWindowFrame OpenDocumentWithSpecificEditor(
IServiceProvider provider,
string fullPath,
Guid editorType,
Guid logicalView
)
参数
- provider
类型:System.IServiceProvider
IServiceProvider .
- fullPath
类型:System.String
文档的绝对路径。
- editorType
类型:System.Guid
编辑类型的 GUID 使用的。
- logicalView
类型:System.Guid
打开的文档的逻辑视图 GUID。
返回值
类型:Microsoft.VisualStudio.Shell.Interop.IVsWindowFrame
将打开文档。窗口的 IVsWindowFrame 接口。
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关更多信息,请参见通过部分受信任的代码使用库。