Name

GetWindowLong

Synopsis

Returns the specified information about a window:

Public Declare Function GetWindowLong Lib "user32" _
		Alias "GetWindowLongA" _
		(ByVal hwnd As Long, ByVal nIndex As Long) As Long

Parameters

hwnd

A window handle.

nIndex

A constant that determines the type of value that this function will return. The GWL_HINSTANCE constant (or -6) must be provided to the nIndex parameter to return the application’s instance handle.

Return Value

If successful, returns the value requested. Otherwise, returns a zero.

Get Subclassing and Hooking with Visual Basic now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.