Show / Hide Table of Contents

Method SetForegroundWindow

| Edit this page View Source

SetForegroundWindow(nint)

Brings the thread that created the specified window into the foreground and activates the window.

Declaration
public static bool SetForegroundWindow(nint hWnd)
Parameters
Type Name Description
nint hWnd

A handle to the window that should be activated and brought to the foreground.

Returns
Type Description
bool

true if the window was brought to the foreground.

false if the window was not brought to the foreground.

Remarks

Learn more about this API from docs.microsoft.com.

  • Edit this page
  • View Source
In this article
Back to top Generated by DocFX