Skip to content

Latest commit

 

History

History
88 lines (68 loc) · 3.82 KB

SendMessage.md

File metadata and controls

88 lines (68 loc) · 3.82 KB

Home

Function name : SendMessage

Group: Message and Message Queue - Library: user32


Sends the specified message to a window or windows. It calls the window procedure for the specified window and does not return until the window procedure has processed the message.


Code examples:

How to view icons stored in executable files (Icon Viewer) - II
System Image List Viewer
Creating irregularly shaped FoxPro form using transparency color key
Round FoxPro form
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 Common Controls: the Header Control
Extended MessageBox Class
How to change the name and the size of the font in the MessageBox dialog
Using Video Capture: displaying on FoxPro form frames and previewing video obtained from a digital camera
How to disable the Windows Clipboard (VFP9)
Accessing Adobe Reader 7.0 main menu from VFP application
How to draw custom Window Caption on FoxPro form
Displaying the associated icons and descriptions for files and folders
Using WM_COPYDATA for interprocess communication (VFP9)
How to view system icons for the classes installed on the local machine
Enumerating devices installed on the local machine
How to control Adobe Reader 9.0 (SDI mode) from VFP application
Displaying hypertext links with the SysLink control (VFP9, Comctl32.dll)
Using Month Calendar Control (VFP9, Comctl32.dll)
Detecting changes in connections to removable drives (VFP9)
Windows Shell Icons displayed and exported to ICO files (Vista)
Browsing Windows Known Folders (Special Folders)
Obtaining names and positions for shortcuts located on the Windows Desktop
Moving shortcut to a specified position on the Windows Desktop
Controlling master audio volume by sending WM_APPCOMMAND messages

Declaration:

LRESULT SendMessage(
  HWND hWnd,      // handle to destination window
  UINT Msg,       // message
  WPARAM wParam,  // first message parameter
  LPARAM lParam   // second message parameter
);  

FoxPro declaration:

DECLARE INTEGER SendMessage IN user32;
	INTEGER hWnd,;
	INTEGER Msg,;
	INTEGER wParam,;
	INTEGER lParam
  

Parameters:

hWnd [in] Handle to the window whose window procedure will receive the message.

Msg [in] Specifies the message to be sent.

wParam [in] Specifies additional message-specific information.

lParam [in] Specifies additional message-specific information.


Return value:

The return value specifies the result of the message processing; it depends on the message sent.


Comments:

To send a message and return immediately, use the SendMessageCallback or SendNotifyMessage function. To post a message to the message queue of a thread and return immediately, use the PostMessage or PostThreadMessage function.