Aracılığıyla paylaş


IVsUIShellOpenDocument.OpenStandardEditor Method

Definition

Opens the standard editor.

public:
 int OpenStandardEditor(System::UInt32 grfOpenStandard, System::String ^ pszMkDocument, Guid % rguidLogicalView, System::String ^ pszOwnerCaption, Microsoft::VisualStudio::Shell::Interop::IVsUIHierarchy ^ pHier, System::UInt32 itemid, IntPtr punkDocDataExisting, Microsoft::VisualStudio::OLE::Interop::IServiceProvider ^ psp, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IVsWindowFrame ^ % ppWindowFrame);
public int OpenStandardEditor (uint grfOpenStandard, string pszMkDocument, ref Guid rguidLogicalView, string pszOwnerCaption, Microsoft.VisualStudio.Shell.Interop.IVsUIHierarchy pHier, uint itemid, IntPtr punkDocDataExisting, Microsoft.VisualStudio.OLE.Interop.IServiceProvider psp, out Microsoft.VisualStudio.Shell.Interop.IVsWindowFrame ppWindowFrame);
abstract member OpenStandardEditor : uint32 * string * Guid * string * Microsoft.VisualStudio.Shell.Interop.IVsUIHierarchy * uint32 * nativeint * Microsoft.VisualStudio.OLE.Interop.IServiceProvider * IVsWindowFrame -> int
Public Function OpenStandardEditor (grfOpenStandard As UInteger, pszMkDocument As String, ByRef rguidLogicalView As Guid, pszOwnerCaption As String, pHier As IVsUIHierarchy, itemid As UInteger, punkDocDataExisting As IntPtr, psp As IServiceProvider, ByRef ppWindowFrame As IVsWindowFrame) As Integer

Parameters

grfOpenStandard
UInt32

[in] Flags whose values are taken from the __VSOSEFLAGS enumeration.

pszMkDocument
String

[in] String form of the unique moniker identifier of the document in the project system, for example, the full path to the file. In non-file cases, this identifier is often in the form of a URL.

rguidLogicalView
Guid

[in] GUID identifying the logical view. If the editor implements IVsMultiViewDocumentView on the document view object, then the value passed into the rguidLogicalView parameter determines which view is activated when the editor window is shown. By specifying the logical view GUID, you can request the specific view that matches the reason you are requesting the view. For example, specify LOGVIEWID_Debugging to get the view appropriate for debugging, or LOGVIEWID_TextView to get the view appropriate for the text editor (that is, a view that implements IVsCodeWindow).

pszOwnerCaption
String

[in] Initial caption defined by the document owner (that is, the project) for the document window. This is often of the form: "ProjectName – ItemName."

pHier
IVsUIHierarchy

[in] Pointer to the IVsUIHierarchy interface.

itemid
UInt32

[in] UI hierarchy item identifier of the standard editor. For more information see VSITEMID.

punkDocDataExisting
IntPtr

nativeint

[in] Pointer to the IUnknown interface of the document data object.

psp
IServiceProvider

[in] Pointer to the IServiceProvider interface.

ppWindowFrame
IVsWindowFrame

[out, retval] Pointer to the IVsWindowFrame interface.

Returns

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

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsUIShellOpenDocument::OpenStandardEditor(  
   [in] VSOSEFLAGS grfOpenStandard,  
   [in] LPCOLESTR pszMkDocument,  
   [in] REFGUID rguidLogicalView,  
   [in] LPCOLESTR pszOwnerCaption,  
   [in] IVsUIHierarchy *pHier,  
   [in] VSITEMID itemid,  
   [in] IUnknown *punkDocDataExisting,  
   [in] IServiceProvider *pSP,  
   [out, retval] IVsWindowFrame **ppWindowFrame  
);  

This method does not call back OpenItem.

Applies to