Using Win32 functions in Visual FoxPro Image Gallery
Window Class
..msdn
GetClassInfo
GetClassInfoEx
GetClassLong
GetClassName
GetWindowLong
RegisterClassEx
SetWindowLong
UnregisterClass
Code examples:
Adding user-defined items to the Control Menu of VFP form (requires VFP9)
Browsing Windows Known Folders (Special Folders)
Capturing keyboard activity of another application with the Raw Input API (VFP9)
Creating irregularly shaped FoxPro form using transparency color key
Customizing the frame of top-level form: removing the standard frame (VFP9, Vista)
Detecting changes in connections to removable drives (VFP9)
Displaying dimmed window behind VFP top-level form
Displaying hypertext links with the SysLink control (VFP9, Comctl32.dll)
Displaying icons in the system tray (VFP9)
Displaying the associated icons and descriptions for files and folders
Dragging files from Explorer window and dropping them on FoxPro control (requires VFP9)
Extended MessageBox Class
How to block the PrintScreen key
How to disable the Windows Clipboard (VFP9)
How to hot-track menu item selection in top-level form (requires VFP9)
How to make a VFP form fading out when released (GDI version)
How to make a VFP form fading out when released (GDI+ version)
How to view icons stored in executable files (Icon Viewer) - II
Locking the workstation
Placing a button on the VFP form as a new child window
Retrieving information about the main VFP window
Semi-transparent Form
Setting properties of the window: caption and user-defined value
Switching between keyboard layouts
System Image List Viewer
Transparent Menu Class (requires VFP9)
Using Common Controls: the Header Control
Using FoxTray ActiveX control: System Tray Icon and menu attached to VFP form
Using Month Calendar Control (VFP9, Comctl32.dll)
Using WM_COPYDATA for interprocess communication (VFP9)
Windows Shell Icons displayed and exported to ICO files (Vista)
GetWindowLong
..msdn    Add comment     W32 Constants      Translate this page
Retrieves information about the specified window. The function also retrieves the 32-bit (long) value at the specified offset into the extra window memory.
Code examples:
Capturing keyboard activity of another application with the Raw Input API (VFP9)
Windows Shell Icons displayed and exported to ICO files (Vista)
Using WM_COPYDATA for interprocess communication (VFP9)
Using FoxTray ActiveX control: System Tray Icon and menu attached to VFP form
Detecting changes in connections to removable drives (VFP9)
Displaying dimmed window behind VFP top-level form
Using Month Calendar Control (VFP9, Comctl32.dll)
Displaying the associated icons and descriptions for files and folders
Transparent Menu Class (requires VFP9)
How to hot-track menu item selection in top-level form (requires VFP9)
Declaration:
LONG GetWindowLong(
  HWND hWnd,  // handle to window
  int nIndex  // offset of value to retrieve
);
FoxPro declaration:
DECLARE INTEGER GetWindowLong IN user32;
    INTEGER hWnd, INTEGER nIndex

Parameters:
hWnd
[in] Handle to the window and, indirectly, the class to which the window belongs.

nIndex
[in] Specifies the zero-based offset to the value to be retrieved.

Return value:
If the function succeeds, the return value is the requested 32-bit value.
If the function fails, the return value is zero.
Usage:
#DEFINE GWL_WNDPROC -4
hWinProc = GetWindowLong(_screen.HWND, GWL_WNDPROC)
My comment:
This function, as well as GetModuleHandle, retrieves a handle to the application instance; but not only.

See also: SetWindowLong
Word Index links for the GetWindowLong :
Translate this page:
  Spanish    Portuguese    German    French    Italian  
FreeTranslation.com offers instant, free translations of text or web pages.
Created: 2001-08-21 12:00:00
Modified: 2007-06-11 16:20:53
Visited in last 7 days: 120
User Contributed Notes:
There are no notes on this subject.


Copyright 2001-2014 News2News, Inc. Before reproducing or distributing any data from this site please ask for an approval from its owner. Unless otherwise specified, this page is for your personal and non-commercial use. The information on this page is presented AS IS, meaning that you may use it at your own risk. Microsoft Visual FoxPro and Windows are trade marks of Microsoft Corp. All other trademarks are the property of their respective owners. 

Privacy policy
Credits: PHP (4.4.9), an HTML-embedded scripting language, MySQL (5.1.68), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
Last Topics Visited (54.211.180.175)
2 day(s)Example: 'HOWTO: Use the Win32 API to Access File Dates and Times'
 Function: 'mmioCreateChunk'
Function group: 'Windows Multimedia'
 Function: 'NetApiBufferFree'
 Function: 'NetShareEnum'
 Function: 'GetProcessHeap'
 Function: 'CloseHandle'
Google
Advertise here!