IVsUIShell.SetForegroundWindow 方法

定义

通过调用 SetForegroundWindow Win32 API 激活环境应用程序窗口。

public:
 int SetForegroundWindow();
public:
 int SetForegroundWindow();
int SetForegroundWindow();
public int SetForegroundWindow ();
abstract member SetForegroundWindow : unit -> int
Public Function SetForegroundWindow () As Integer

返回

Int32

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

注解

此方法将创建指定窗口的线程置于前台,并激活窗口。 键盘输入将定向到窗口,并为用户更改各种视觉提示。

适用于