IVsDebugger2.ShowSource 方法

定义

在 IDE 中显示源文件。 将指向 IUnknown 接口的指针作为参数使用,该接口可用于查询 IDebugDocumentContext2 和显示选项。

public:
 int ShowSource(System::Object ^ pUnkDebugDocContext, int fMakeActive, int fAlwaysMoveCaret, int fPromptToFindSource, int fIgnoreIfNotFound, [Runtime::InteropServices::Out] Microsoft::VisualStudio::TextManager::Interop::IVsTextView ^ % ppTextView);
public:
 int ShowSource(Platform::Object ^ pUnkDebugDocContext, int fMakeActive, int fAlwaysMoveCaret, int fPromptToFindSource, int fIgnoreIfNotFound, [Runtime::InteropServices::Out] Microsoft::VisualStudio::TextManager::Interop::IVsTextView ^ &  ppTextView);
int ShowSource(winrt::Windows::Foundation::IInspectable const & pUnkDebugDocContext, int fMakeActive, int fAlwaysMoveCaret, int fPromptToFindSource, int fIgnoreIfNotFound, [Runtime::InteropServices::Out] Microsoft::VisualStudio::TextManager::Interop::IVsTextView const & & ppTextView);
public int ShowSource (object pUnkDebugDocContext, int fMakeActive, int fAlwaysMoveCaret, int fPromptToFindSource, int fIgnoreIfNotFound, out Microsoft.VisualStudio.TextManager.Interop.IVsTextView ppTextView);
abstract member ShowSource : obj * int * int * int * int * IVsTextView -> int
Public Function ShowSource (pUnkDebugDocContext As Object, fMakeActive As Integer, fAlwaysMoveCaret As Integer, fPromptToFindSource As Integer, fIgnoreIfNotFound As Integer, ByRef ppTextView As IVsTextView) As Integer

参数

pUnkDebugDocContext
Object

中指向 IUnknown 实现 IDebugDocumentContext2 的对象上的接口的指针。

fMakeActive
Int32

中变量. 如果 true 为,则使源文件窗口成为活动窗口。

fAlwaysMoveCaret
Int32

中变量. 如果 true 为,则通过 IDebugDocumentContext2 接口的 IDebugDocumentContext2:: GetStatementRange 方法将插入符号移动到文档上下文指示的位置。

fPromptToFindSource
Int32

中变量. 如果 true 为,则在找不到文件时提示用户。

fIgnoreIfNotFound
Int32

中变量. 如果 true 为,则在将来找不到该文件(如果当前未找到)。

ppTextView
IVsTextView

弄指向表示已 IVsTextView 打开源视图的接口的指针。 可为 null

返回

Int32

如果该方法成功,则它会返回 S_OK。 如果该方法失败,则会返回错误代码。

注解

COM 签名

从 vsshell80:

HRESULT IVsDebugger2::ShowSource(  
   [in] IUnknown *pUnkDebugDocContext,  
   [in] BOOL fMakeActive,  
   [in] BOOL fAlwaysMoveCaret,  
   [in] BOOL fPromptToFindSource,  
   [in] BOOL fIgnoreIfNotFound,  
   [out] IVsTextView **ppTextView  
);  

适用于