IVsUIShellOpenDocument::OpenStandardEditor Method (UInt32, String^, Guid, String^, IVsUIHierarchy^, UInt32, IntPtr, IServiceProvider^, IVsWindowFrame^)

 

Opens the standard editor.

Namespace:   Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)

int OpenStandardEditor(
	unsigned int grfOpenStandard,
	String^ pszMkDocument,
	[InAttribute] Guid% rguidLogicalView,
	String^ pszOwnerCaption,
	IVsUIHierarchy^ pHier,
	unsigned int itemid,
	IntPtr punkDocDataExisting,
	IServiceProvider^ psp,
	[OutAttribute] IVsWindowFrame^% ppWindowFrame
)

Parameters

grfOpenStandard
Type: System::UInt32

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

pszMkDocument
Type: System::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
Type: System::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
Type: System::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
Type: Microsoft.VisualStudio.Shell.Interop::IVsUIHierarchy^

[in] Pointer to the IVsUIHierarchy interface.

itemid
Type: System::UInt32

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

punkDocDataExisting
Type: System::IntPtr

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

psp
Type: Microsoft.VisualStudio.OLE.Interop::IServiceProvider^

[in] Pointer to the IServiceProvider interface.

ppWindowFrame
Type: Microsoft.VisualStudio.Shell.Interop::IVsWindowFrame^

[out, retval] Pointer to the IVsWindowFrame interface.

Return Value

Type: System::Int32

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

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.

Return to top
Show: