Group: Keyboard Input - Library: user32
Retrieves the handle to the window that has the keyboard focus, if the window is attached to the calling thread"s message queue.
Retrieving window and menu help context identifiers
GetFocus returns a HWND value
How to copy the image of a form to the Clipboard using Bitmap API functions
Drawing standard Windows icons
How to view icons stored in executable files (Icon Viewer)
Setting the Window Region for a form
Using FrameRgn for displaying system colors
How to create transparent areas inside a form -- punching holes in the form
An alternative way of setting Form.Closable to False
Round FoxPro form
Creating a clipping region from the path selected into the device context of a form
How to print FoxPro form
Storing screen shot of a form to bitmap file
How to drag a Form not using its Titlebar or Caption
How to start the screen saver and how to find whether the screen saver is active
Using IsChild() for testing ThisForm.ShowWindow property
Attaching menu to a top-level form
Retrieving top-child window for the VFP form
Drawing a window caption using the DrawCaption routine
Running a regular FoxPro form while main VFP window is minimized
Animating a transition of the VFP form (a wire-frame rectangle)
Disabling drawing in the VFP form
The window and its ancestors
Placing a button on the VFP form as a new child window
Tracking mouse movement to detect when to start dragging
Setting the mouse capture to the specified window
Using Common Controls: the Header Control
How to intercept window messages sent to VFP form
Dragging files from Explorer window and dropping them on FoxPro control (requires VFP9)
How to put a horizontal text scrolling on the form (a news line, marquee)
How to put a vertical text scrolling on the form (a movie cast)
Displaying animated images on FoxPro form with BitBlt and StretchBlt functions
Storing screen shot of a form to enhanced metafile (*.emf)
Copying picture of the active form to the Clipboard using Enhanced Metafile API functions
How to print FoxPro form -- II
Form Magnifier
Shortcut Menu Class
How to block the ALT+TAB shortcut (WinXP)
GDI+: saving image of FoxPro form to graphics file (BMP, GIF, JPG, PNG, TIF)
GDI+: sending image of FoxPro form to printer
GDI+: copying to the Clipboard (a) image of active FoxPro window/form, (b) image file
How to block the PrintScreen key
HWND GetFocus(VOID); DECLARE INTEGER GetFocus IN user32 This function has no parameters.
The return value is the handle to the window with the keyboard focus. If the calling thread"s message queue does not have an associated window with the keyboard focus, the return value is NULL.
This function returns a window handle to an active form, or for the main VFP window if it has the keyboard focus. In this case its result is equivalent to the one of GetActiveWindow.
See also: SetFocus, SetForegroundWindow, GetForegroundWindow, GetActiveWindow.
Home