IVsDebugger2.ShowSource Method
Displays a source file in the IDE. Takes as arguments a pointer to an IUnknown interface that can be queried for IDebugDocumentContext2 and display options.
Namespace: Microsoft.VisualStudio.Shell.Interop
Assembly: Microsoft.VisualStudio.Shell.Interop.8.0 (in Microsoft.VisualStudio.Shell.Interop.8.0.dll)
Syntax
'宣告
Function ShowSource ( _
pUnkDebugDocContext As Object, _
fMakeActive As Integer, _
fAlwaysMoveCaret As Integer, _
fPromptToFindSource As Integer, _
fIgnoreIfNotFound As Integer, _
<OutAttribute> ByRef ppTextView As IVsTextView _
) As Integer
'用途
Dim instance As IVsDebugger2
Dim pUnkDebugDocContext As Object
Dim fMakeActive As Integer
Dim fAlwaysMoveCaret As Integer
Dim fPromptToFindSource As Integer
Dim fIgnoreIfNotFound As Integer
Dim ppTextView As IVsTextView
Dim returnValue As Integer
returnValue = instance.ShowSource(pUnkDebugDocContext, _
fMakeActive, fAlwaysMoveCaret, fPromptToFindSource, _
fIgnoreIfNotFound, ppTextView)
int ShowSource(
Object pUnkDebugDocContext,
int fMakeActive,
int fAlwaysMoveCaret,
int fPromptToFindSource,
int fIgnoreIfNotFound,
out IVsTextView ppTextView
)
int ShowSource(
[InAttribute] Object^ pUnkDebugDocContext,
[InAttribute] int fMakeActive,
[InAttribute] int fAlwaysMoveCaret,
[InAttribute] int fPromptToFindSource,
[InAttribute] int fIgnoreIfNotFound,
[OutAttribute] IVsTextView^% ppTextView
)
abstract ShowSource :
pUnkDebugDocContext:Object *
fMakeActive:int *
fAlwaysMoveCaret:int *
fPromptToFindSource:int *
fIgnoreIfNotFound:int *
ppTextView:IVsTextView byref -> int
function ShowSource(
pUnkDebugDocContext : Object,
fMakeActive : int,
fAlwaysMoveCaret : int,
fPromptToFindSource : int,
fIgnoreIfNotFound : int,
ppTextView : IVsTextView
) : int
Parameters
- pUnkDebugDocContext
Type: System.Object
[in] Pointer to an IUnknown interface on an object implementing IDebugDocumentContext2.
- fMakeActive
Type: System.Int32
[in] Boolean. If true, makes the source file window the active window.
- fAlwaysMoveCaret
Type: System.Int32
[in] Boolean. If true, move the caret to the position indicated by the document context through the IDebugDocumentContext2::GetStatementRange method of the IDebugDocumentContext2 interface.
- fPromptToFindSource
Type: System.Int32
[in] Boolean. If true, prompt the user if the file is not found.
- fIgnoreIfNotFound
Type: System.Int32
[in] Boolean. If true, do not try to find the file in the future if it is not found now.
- ppTextView
Type: Microsoft.VisualStudio.TextManager.Interop.IVsTextView%
[out] Pointer to a IVsTextView interface representing the opened source view. May be nulla null reference (Nothing in Visual Basic).
Return Value
Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.
Remarks
COM Signature
From vsshell80.idl:
HRESULT IVsDebugger2::ShowSource(
[in] IUnknown *pUnkDebugDocContext,
[in] BOOL fMakeActive,
[in] BOOL fAlwaysMoveCaret,
[in] BOOL fPromptToFindSource,
[in] BOOL fIgnoreIfNotFound,
[out] IVsTextView **ppTextView
);
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.