Desktop Functions: Smart Device Functions:
|
Search Results for "HWND" in [All]odbc32
IntPtr hwnd,
Private Shared Function SQLDriverConnect(ByVal hdbc As IntPtr, ByVal hwnd As IntPtr, ByVal szConnStrIn As String, _ wintrust
[In] IntPtr hwnd,
[In] IntPtr hwnd, wininet3: InternetDial private static extern Int32 InternetDial(IntPtr hwndParent, string lpszConnectoid, Int32 dwFlags, ref Int32 lpdwConnection, Int32 dwReserved); irprops
static extern uint BluetoothAuthenticateDeviceEx(IntPtr hwndParentIn, IntPtr hRadioIn, ref BLUETOOTH_DEVICE_INFO pbtdiInout, BLUETOOTH_OOB_DATA pbtOobData, uint authenticationRequirement);
static extern uint BluetoothAuthenticateDeviceEx(IntPtr hwndParentIn, IntPtr hRadioIn, ref BLUETOOTH_DEVICE_INFO pbtdiInout, BLUETOOTH_OOB_DATA pbtOobData, uint authenticationRequirement); imm32
IntPtr hWnd,
public static extern IntPtr ImmGetContext(IntPtr hWnd);
Declare Function ImmGetContext Lib "Imm32.dll" (hWnd As Intptr) As Intptr
Friend Shared Function ImmGetContext(hWnd As IntPtr) As IntPtr
public static extern IntPtr ImmGetContext(IntPtr hwnd);
public static extern int ImmSimulateHotKey(IntPtr hwnd, int lngHotkey);
public string[] GetReverseConversion(IntPtr AHwnd,string AText)
IntPtr hIMC = ImmGetContext(AHwnd);
public static extern bool ImmReleaseContext(IntPtr hWnd,IntPtr hIMC); user32
static extern bool AddClipboardFormatListener(IntPtr hwnd);
Public Function AddClipboardFormatListener(hWnd As IntPtr) As <MarshalAs(UnmanagedType.Bool)>Boolean
Declare Function AddClipboardFormatListener Lib "user32.dll" (hWnd As Long) As Boolean 11: AnimateWindow
static extern bool AnimateWindow(IntPtr hwnd, int time, AnimateWindowFlags flags);
Shared Function AnimateWindow(ByVal hwnd As IntPtr, ByVal time As Integer, ByVal flags As AnimateWindowFlags) As Boolean 12: AppendMenu
Private Shared Function GetSystemMenu(ByVal hWnd As IntPtr, ByVal bRevert As Boolean) As IntPtr
static extern uint ArrangeIconicWindows(IntPtr hWnd); 14: BeginPaint
static extern IntPtr BeginPaint(IntPtr hwnd, out PAINTSTRUCT lpPaint);
Public Shared Function BeginPaint(ByVal hwnd As IntPtr, <Out()> ByRef lpPaint As PAINTSTRUCT) As IntPtr 15: BringWindowToTop
static extern bool BringWindowToTop(IntPtr hWnd);
static extern bool BringWindowToTop(HandleRef hWnd);
Private Shared Function BringWindowToTop(ByVal hwnd As IntPtr) As Boolean
Public Declare Function BringWindowToTop Lib "user32" (ByVal HWnd As IntPtr) As Boolean 16: CallWindowProc
static extern IntPtr CallWindowProc(WndProcDelegate lpPrevWndFunc, IntPtr hWnd, uint Msg, IntPtr wParam, IntPtr lParam);
Private Shared Function CallWindowProc(lpPrevWndFunc As WndProcDelegate, hWnd As IntPtr, Msg As UInteger, wParam As IntPtr, lParam As IntPtr) As IntPtr 17: CascadeWindows
static extern ushort CascadeWindows(IntPtr hwndParent, uint wHow,
static extern bool ChangeClipboardChain(IntPtr hWndRemove, IntPtr hWndNewNext);
static extern DISP_CHANGE ChangeDisplaySettingsEx(string lpszDeviceName, ref DEVMODE lpDevMode, IntPtr hwnd, ChangeDisplaySettingsFlags dwflags, IntPtr lParam);
Private Shared Function ChangeDisplaySettingsEx(ByVal lpszDeviceName As String, ByRef lpDevMode As DEVMODE, ByVal hwnd As IntPtr, ByVal dwflags As UInteger, ByVal lParam As IntPtr) As DISP_CHANGE
public static extern bool ChangeWindowMessageFilterEx(IntPtr hWnd, uint msg, ChangeWindowMessageFilterExAction action,ref CHANGEFILTERSTRUCT changeInfo);
Private Shared Function ChangeWindowMessageFilterEx(hWnd As IntPtr, msg As UInteger, action As ChangeWindowMessageFilterExAction, ByRef changeInfo As CHANGEFILTERSTRUCT) As <MarshalAs(UnmanagedType.Bool)> Boolean
static extern IntPtr ChildWindowFromPointEx(IntPtr hWndParent, Point pt, uint uFlags);
Public Function ChildWindowFromPointEx(ByVal hWndParent As IntPtr, ByVal P As POINTAPI, ByVal uFlags As CWPFlags) As IntPtr
static extern IntPtr ChildWindowFromPointEx(IntPtr hWndParent, Point pt, uint uFlags);
Public Function ChildWindowFromPointEx(ByVal hWndParent As IntPtr, ByVal P As POINTAPI, ByVal uFlags As CWPFlags) As IntPtr 23: ClientToScreen
static extern bool ClientToScreen(IntPtr hWnd, ref Point lpPoint);
Private Shared Function ClientToScreen(ByVal hWnd As IntPtr, ByRef lpPoint As Point) As Boolean
static extern bool ClientToScreen(IntPtr hwnd, ref Point lpPoint); 24: CloseWindow
static extern int CloseWindow (IntPtr hWnd); 25: CreateCaret
static extern bool CreateCaret(IntPtr hWnd, IntPtr hBitmap, int nWidth,
Public Shared Function CreateCaret(ByVal hWnd As IntPtr, ByVal hBitmap As IntPtr, ByVal nWidth As Integer, ByVal nHeight As Integer) As Boolean
Public Shared Function CreateCaret(ByVal hWnd As IntPtr, ByVal hBitmap As IntPtr, ByVal nWidth As Integer, ByVal nHeight As Integer) As Boolean 26: CreateMDIWindow
IntPtr hwndParent, 27: CreateWindowEx
/// <param name="nHeight">Specifies the height, in device units, of the window. For overlapped windows, nHeight is the window's height, in screen coordinates. If the nWidth parameter is set to CW_USEDEFAULT, the system ignores nHeight.</param> <param name="hWndParent">Handle to the parent or owner window of the window being created. To create a child window or an owned window, supply a valid window handle. This parameter is optional for pop-up windows.
/// <para>Windows 2000/XP: To create a message-only window, supply HWND_MESSAGE or a handle to an existing message-only window.</para></param>
IntPtr hWndParent,
''' <param name="nHeight">Specifies the height, in device units, of the window. For overlapped windows, nHeight is the window's height, in screen coordinates. If the nWidth parameter is set to CW_USEDEFAULT, the system ignores nHeight.</param> <param name="hWndParent">Handle to the parent or owner window of the window being created. To create a child window or an owned window, supply a valid window handle. This parameter is optional for pop-up windows.
''' <para>Windows 2000/XP: To create a message-only window, supply HWND_MESSAGE or a handle to an existing message-only window.</para></param>
ByVal hWndParent As IntPtr, _
wndclass.lpfnWndProc = (WndProc)((hWnd, message, wParam, lParam ) => {
hdc = Win32.BeginPaint (hWnd, out ps) ;
Win32.GetClientRect (hWnd, out rect) ;
Win32.EndPaint(hWnd, ref ps);
return Win32.DefWindowProc(hWnd, (WM)message, wParam, lParam);
IntPtr hwnd = Win32.CreateWindowEx(
if( hwnd == IntPtr.Zero )
Win32.ShowWindow(hwnd, ShowWindowCommands.Normal );
Win32.UpdateWindow(hwnd);
///<Summary>Does not activate the window. If this flag is not set, the window is activated and moved to the top of either the topmost or non-topmost group (depending on the setting of the hWndInsertAfter parameter).</Summary>
///<Summary>Retains the current Z order (ignores the hWndInsertAfter parameter).</Summary>
'''<Summary>Does not activate the window. If this flag is not set, the window is activated and moved to the top of either the topmost or non-topmost group (depending on the setting of the hWndInsertAfter parameter).</Summary>
'''<Summary>Retains the current Z order (ignores the hWndInsertAfter parameter).</Summary> 29: DefWindowProc
static extern IntPtr DefWindowProc(IntPtr hWnd, WindowsMessages uMsg, IntPtr wParam, IntPtr lParam);
Public Shared Function DefWindowProc(ByVal hWnd As IntPtr, ByVal uMsg As WindowsMessages, ByVal wParam As IntPtr, ByVal lParam As IntPtr) As IntPtr
public static extern bool DeregisterShellHookWindow(IntPtr hWnd); 31: DestroyWindow
/// <param name="hwnd">Handle to the window to be destroyed.</param>
static extern bool DestroyWindow(IntPtr hwnd);
''' <param name="hwnd">Handle to the window to be destroyed.</param>
Private Shared Function DestroyWindow(hwnd As IntPtr) As <MarshalAs(UnmanagedType.Bool)> Boolean hWnd is the pointer to the window you want to close/destroy. Create a new IntPtr object with the window's handle as a parameter to it's constructor. Make sure the pointers are in decimal, not in hex as spy++ gives them to you.
static extern bool DestroyWindow(IntPtr hWnd); 32: DragDetect
static extern bool DragDetect(IntPtr hwnd, POINT pt);
public static bool DragDetect(IntPtr hWnd, Point pt) {
static extern bool DrawAnimatedRects(IntPtr hwnd, int idAni,
static extern bool DrawAnimatedRects(System.IntPtr hwnd, int idAni,
static extern System.IntPtr FindWindowEx(System.IntPtr hwndParent, System.IntPtr hwndChildAfter,
static extern bool GetWindowRect(System.IntPtr hWnd, out RECT lpRect);
System.IntPtr hWnd =
if (hWnd != System.IntPtr.Zero)
GetWindowRect(hWnd, out to);
bool DrawAnimatedRects(int hwnd, int idAni, RECT^ lprcFrom, RECT^ lprcTo);
int FindWindowEx(int hwndParent, int hwndChildAfter,
bool GetWindowRect(int hWnd, RECT^ lpRect);
int hWnd=FindWindowEx(FindWindow("Shell_TrayWnd", nullptr), 0, "TrayNotifyWnd", nullptr);
if (hWnd != 0) {
GetWindowRect(hWnd, to); 34: DrawMenuBar
static extern bool DrawMenuBar(IntPtr hWnd);
static extern IntPtr GetSystemMenu(IntPtr hWnd, bool bRevert);
static extern bool DrawMenuBar(IntPtr hWnd); 35: EnableMenuItem
Private Shared Function GetSystemMenu(ByVal hWnd As IntPtr, ByVal bRevert As Boolean) As IntPtr 36: EnableScrollBar
static extern bool EnableScrollBar(IntPtr hWnd, uint wSBflags, uint wArrows);
Private Shared Function EnableScrollBar(ByVal hWnd As IntPtr, <MarshalAs(UnmanagedType.U4)>wSBflags As SBFlags, <MarshalAs(UnmanagedType.U4)>wArrows As SBArrows) As <MarshalAs(UnmanagedType.Bool)>Boolean
(ByVal hWnd As Long, _
static extern bool EnableScrollBar(IntPtr hWnd, uint wSBflags, uint wArrows); 37: EnableWindow
static extern bool EnableWindow(IntPtr hWnd, bool bEnable);
Private Shared Function EnableWindow(ByVal hWnd As IntPtr, ByVal bEnable As Boolean) As Boolean
static extern bool EnableWindow(IntPtr hWnd, bool bEnable); 38: EndDialog
IntPtr hwnd = FindWindowByCaption((IntPtr)null, "Untitled - Notepad");
if (null != hwnd)
EndDialog(hwnd, result); 39: EndPaint
static extern bool EndPaint(IntPtr hWnd, [In] ref PAINTSTRUCT lpPaint);
Public Shared Function EndPaint(ByVal hwnd As IntPtr, <[In]()> ByRef lpPaint As PAINTSTRUCT) As IntPtr 40: EndTask
static extern bool EndTask(IntPtr hWnd, bool fShutDown, bool fForce);
Private Shared Function EndTask(hWnd As IntPtr, fShutDown As Boolean, fForce As Boolean) As Boolean
public static extern bool EndTask(IntPtr hWnd, bool fShutDown,bool fForce);
Public Shared Function EndTask(hWnd As IntPtr, fShutDown As Boolean, fForce As Boolean) As Boolean 41: EnumChildWindows
public delegate bool EnumWindowsProc(IntPtr hwnd, IntPtr lParam);
public static extern bool EnumChildWindows(IntPtr hwndParent, EnumWindowsProc lpEnumFunc, IntPtr lParam);
Private Shared Function EnumChildWindows(ByVal hWndParent As System.IntPtr, ByVal lpEnumFunc As EnumWindowsProc, ByVal lParam As Integer) As Boolean
/// <param name="hWnd">Window handle</param>
public delegate bool EnumWindowProc(IntPtr hWnd, IntPtr parameter);
static extern bool OpenClipboard(IntPtr hWndNewOwner);
private delegate bool EnumDesktopWindowsDelegate(IntPtr hWnd, int lParam);
/// <param name="hWnd"></param>
public delegate bool EnumDelegate(IntPtr hWnd, int lParam);
/// <param name="hWnd"></param>
public static extern bool IsWindowVisible(IntPtr hWnd);
/// <param name="hWnd"></param>
public static extern int GetWindowText(IntPtr hWnd, StringBuilder lpWindowText, int nMaxCount);
user32.EnumDelegate filter = delegate(IntPtr hWnd, int lParam)
int nLength = user32.GetWindowText(hWnd, strbTitle, strbTitle.Capacity + 1);
if (user32.IsWindowVisible(hWnd) && string.IsNullOrEmpty(strTitle) == false) 44: EnumProps
static extern int EnumPropsEx(IntPtr hWnd, EnumPropsExDelegate lpEnumFunc,
static extern int EnumPropsEx(IntPtr hWnd, EnumPropsExDelegate lpEnumFunc, IntPtr lParam);
private delegate int EnumPropsExDelegate(IntPtr hwnd, IntPtr lpszString, IntPtr hData, IntPtr dwData);
IntPtr hWnd = new IntPtr(XXXXXX); //Enter handle value here. use UI Spy/Inspect to get it
var i = EnumPropsEx(hWnd, enumPropsExDel, new IntPtr());
public static int PropEnumProcEx(IntPtr hwnd, IntPtr lpszString, IntPtr hData, IntPtr dwData) 45: EnumPropsEx
static extern int EnumPropsEx(IntPtr hWnd, EnumPropsExDelegate lpEnumFunc,
static extern int EnumPropsEx(IntPtr hWnd, EnumPropsExDelegate lpEnumFunc, IntPtr lParam);
private delegate int EnumPropsExDelegate(IntPtr hwnd, IntPtr lpszString, long hData, long dwData);
IntPtr hWnd = new IntPtr(XXXXXX); //Enter handle value here. use UI Spy/Inspect to get it
var i = EnumPropsEx(hWnd, enumPropsExDel, new IntPtr());
public static int PropEnumProcEx(IntPtr hwnd, IntPtr lpszString, long hData, long dwData) delegate bool EnumThreadDelegate(IntPtr Hwnd, IntPtr lParam); Delegate Function EnumThreadDelegate(Hwnd As IntPtr, lParam As IntPtr) As Boolean public delegate bool EnumThreadDelegate (IntPtr hwnd, IntPtr lParam);
public delegate bool EnumThreadDelegate (IntPtr hWnd, IntPtr lParam);
static extern bool PostMessage(IntPtr hWnd, uint Msg, IntPtr wParam, IntPtr lParam);
static bool EnumThreadCallback(IntPtr hWnd, IntPtr lParam)
PostMessage(hWnd, WM_CLOSE, IntPtr.Zero, IntPtr.Zero);
Delegate Function EnumThreadDelegate(hWnd As IntPtr, lParam As IntPtr) As Boolean
Shared Function PostMessage(hWnd As IntPtr, Msg As UInteger, wParam As IntPtr, lParam As IntPtr) As<MarshalAs(UnmanagedType.Bool)> Boolean
Shared Function EnumThreadCallback(hWnd As IntPtr, lParam As IntPtr) As Boolean
PostMessage(hWnd, WM_CLOSE, IntPtr.Zero, IntPtr.Zero) 48: FindWindow
static extern IntPtr FindWindowEx(IntPtr hwndParent, IntPtr hwndChildAfter, string lpszClass, string lpszWindow); 49: FindWindowEx
static extern IntPtr FindWindowEx(IntPtr hwndParent, IntPtr hwndChildAfter, string lpszClass, string lpszWindow); 50: FlashWindow
public IntPtr hwnd;
/// <param name="hWnd">The handle to the window to flash</param>
public static bool FlashWindowEx(IntPtr hWnd)
fInfo.hwnd = hWnd;
/// <param name="hWnd">The handle to the window to flash</param>
IntPtr hWnd = frm.Handle;
fInfo.hwnd = hWnd;
Public hwnd As Long
.hwnd = frm.Handle 51: FlashWindowEx
public IntPtr hwnd;
/// <param name="hWnd">The handle to the window to flash</param>
public static bool FlashWindowEx(IntPtr hWnd)
fInfo.hwnd = hWnd;
/// <param name="hWnd">The handle to the window to flash</param>
IntPtr hWnd = frm.Handle;
fInfo.hwnd = hWnd;
Public hwnd As Long
.hwnd = frm.Handle 52: GetActiveWindow Can be used to find the active window Hwnd for GetWindowText 53: GetAltTabInfo
static extern bool GetAltTabInfo(IntPtr hwnd, int iItem, out ALTTABINFO pati,
ByVal hwnd As IntPtr, _ 54: GetAncestor
/// <param name="hwnd">A handle to the window whose ancestor is to be retrieved.
static extern IntPtr GetAncestor(IntPtr hwnd, GetAncestorFlags flags);
Private Shared Function GetAncestor(ByVal hwnd As IntPtr, ByVal gaFlags As GetAncestor_Flags) As IntPtr 55: GetClassLong
public static IntPtr GetClassLongPtr(HandleRef hWnd, int nIndex)
return GetClassLongPtr64(hWnd, nIndex);
return new IntPtr(GetClassLongPtr32(hWnd, nIndex));
public static extern uint GetClassLongPtr32(HandleRef hWnd, int nIndex);
public static extern IntPtr GetClassLongPtr64(HandleRef hWnd, int nIndex);
Public Shared Function GetClassLongPtr(ByVal hWnd As HandleRef, ByVal nIndex As Integer) As IntPtr
Return GetClassLongPtr64(hWnd, nIndex)
Return New IntPtr(GetClassLongPtr32(hWnd, nIndex))
Public Shared Function GetClassLongPtr32(ByVal hWnd As HandleRef, <MarshalAs(UnmanagedType.I4)>nIndex As ClassLongFlags) As UInteger
Public Shared Function GetClassLongPtr64(ByVal hWnd As HandleRef, <MarshalAs(UnmanagedType.I4)>nIndex As ClassLongFlags) As IntPtr
(ByVal hWnd As Long, _ 56: GetClassLongPtr
public static IntPtr GetClassLongPtr(HandleRef hWnd, int nIndex)
return GetClassLongPtr64(hWnd, nIndex);
return new IntPtr(GetClassLongPtr32(hWnd, nIndex));
public static extern uint GetClassLongPtr32(HandleRef hWnd, int nIndex);
public static extern IntPtr GetClassLongPtr64(HandleRef hWnd, int nIndex);
Public Shared Function GetClassLongPtr(ByVal hWnd As HandleRef, ByVal nIndex As Integer) As IntPtr
Return GetClassLongPtr64(hWnd, nIndex)
Return New IntPtr(GetClassLongPtr32(hWnd, nIndex))
Public Shared Function GetClassLongPtr32(ByVal hWnd As HandleRef, ByVal nIndex As Integer) As UInteger
Public Shared Function GetClassLongPtr64(ByVal hWnd As HandleRef, ByVal nIndex As Integer) As IntPtr 57: GetClassName
static extern int GetClassName(IntPtr hWnd, StringBuilder lpClassName,int nMaxCount);
Private Shared Function GetClassName(ByVal hWnd As System.IntPtr, _
Public Declare Auto Function GetClassName Lib "User32.dll" (ByVal hwnd As IntPtr, _
(ByVal hWnd As Long, _
private static bool isIEServerWindow(IntPtr hWnd)
nRet = GetClassName(hWnd, ClassName, ClassName.Capacity); 58: GetClientRect
static extern bool GetClientRect(IntPtr hWnd, out RECT lpRect);
Private Shared Function GetClientRect(ByVal hWnd As System.IntPtr, _
public static RECT GetClientRect(IntPtr hWnd)
GetClientRect(hWnd, out result);
static extern bool OpenClipboard(IntPtr hWndNewOwner); 60: GetComboBoxInfo
public static extern bool GetComboBoxInfo(IntPtr hWnd, ref COMBOBOXINFO pcbi);
Public Shared Function GetComboBoxInfo(ByVal hWnd As IntPtr, ByRef pcbi As COMBOBOXINFO) As Boolean
public IntPtr hwndCombo;
public IntPtr hwndEdit;
public IntPtr hwndList;
Public hwndCombo As IntPtr
Public hwndEdit As IntPtr
Public hwndList As IntPtr
if(cbi.hwndEdit == IntPtr.Zero) { Cut off search results after 60. Please refine your search. |