共用方式為


IVsUIShellOpenDocument Interface

Definition

Controls the state of open documents within the environment.

public interface class IVsUIShellOpenDocument
public interface class IVsUIShellOpenDocument
__interface IVsUIShellOpenDocument
[System.Runtime.InteropServices.Guid("35299EEC-11EE-4518-9F08-401638D1D3BC")]
[System.Runtime.InteropServices.InterfaceType(1)]
public interface IVsUIShellOpenDocument
[System.Runtime.InteropServices.Guid("35299EEC-11EE-4518-9F08-401638D1D3BC")]
[System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)]
public interface IVsUIShellOpenDocument
[<System.Runtime.InteropServices.Guid("35299EEC-11EE-4518-9F08-401638D1D3BC")>]
[<System.Runtime.InteropServices.InterfaceType(1)>]
type IVsUIShellOpenDocument = interface
[<System.Runtime.InteropServices.Guid("35299EEC-11EE-4518-9F08-401638D1D3BC")>]
[<System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)>]
type IVsUIShellOpenDocument = interface
Public Interface IVsUIShellOpenDocument
Attributes

Remarks

See also SVsUIShellOpenDocument service.

To provisionally open a document in the Visual Studio preview tab, use methods on this interface from within a using statement in conjunction with the NewDocumentStateScope class, or use the SetNewDocumentState method.

Notes to Callers

Call to determine whether a document is open, to open a document using various editors, or to preview a document.

Methods

AddStandardPreviewer(String, String, Int32, String, String, String, String, String, UInt32)

Adds a Web browser to the list of available previewers.

GetFirstDefaultPreviewer(String, Int32, Int32)

Returns the .exe file path of the first default web browser.

GetStandardEditorFactory(UInt32, Guid, String, Guid, String, IVsEditorFactory)

Returns the editor factory associated with a specific document (for example, a file type).

InitializeEditorInstance(UInt32, IntPtr, IntPtr, String, Guid, String, Guid, String, String, IVsUIHierarchy, UInt32, IntPtr, IServiceProvider, Guid, IVsWindowFrame)

Initializes an instance of the document editor.

IsDocumentInAProject(String, IVsUIHierarchy, UInt32, IServiceProvider, Int32)

Determines whether a document is part of the project.

IsDocumentOpen(IVsUIHierarchy, UInt32, String, Guid, UInt32, IVsUIHierarchy, UInt32[], IVsWindowFrame, Int32)

Determines whether a document is currently open.

IsSpecificDocumentViewOpen(IVsUIHierarchy, UInt32, String, Guid, String, UInt32, IVsUIHierarchy, UInt32, IVsWindowFrame, Int32)

Determines whether a specified document view is open.

MapLogicalView(Guid, Guid, String)

Maps a physical view to a logical view.

OpenCopyOfStandardEditor(IVsWindowFrame, Guid, IVsWindowFrame)

Used to implement Window.NewWindow functionality.

OpenDocumentViaProject(String, Guid, IServiceProvider, IVsUIHierarchy, UInt32, IVsWindowFrame)

Finds an appropriate project to open the document.

OpenDocumentViaProjectWithSpecific(String, UInt32, Guid, String, Guid, IServiceProvider, IVsUIHierarchy, UInt32, IVsWindowFrame)

Finds a specified project to open this document.

OpenSpecificEditor(UInt32, String, Guid, String, Guid, String, IVsUIHierarchy, UInt32, IntPtr, IServiceProvider, IVsWindowFrame)

Opens a specified editor.

OpenStandardEditor(UInt32, String, Guid, String, IVsUIHierarchy, UInt32, IntPtr, IServiceProvider, IVsWindowFrame)

Opens the standard editor.

OpenStandardPreviewer(UInt32, String, VSPREVIEWRESOLUTION, UInt32)

Opens a standard web browser for the specified document.

SearchProjectsForRelativePath(UInt32, String, String[])

Converts a relative path for a document to an absolute path that can be passed to OpenDocumentViaProject(String, Guid, IServiceProvider, IVsUIHierarchy, UInt32, IVsWindowFrame).

Applies to