DLGSENDCTRLMESSAGE

Run-Time Function: Sends a Windows message to a dialog box control.

Module: USE DFLOGM

Syntax

result = DLGSENDCTRLMESSAGE (dlg, controlid, msg, wparam, lparam)

dlg
(Input) Derived-type DIALOG. Contains dialog box parameters. The components of the type DIALOG are defined with the PRIVATE attribute, and cannot be changed or individually accessed by the user.


controlid
(Input) Integer. Specifies the identifier of the control within the dialog box. Can be either the symbolic name for the control or the identifier number, both listed in the Include file (with extension .FD).


msg
(Input) Integer. Derived type T_MSG. Specifies the message to be sent.


wparam
(Input) Integer. Specifies additional message specific information.


lparam
(Input) Integer. Specifies additional message specific information.

Results:

The result is of type INTEGER(4). The value specifies the result of the message processing and depends upon the message sent.

The dialog box must be currently active by a call to DLGMODAL or DLGMODELESS. This function does not return until the message has been processed by the control.

Compatibility

CONSOLE STANDARD GRAPHICS QUICKWIN GRAPHICS WINDOWS DLL LIB

See Also: DLGINIT, DLGSETSUB, DLGMODAL, DLGMODELESS

Example

use dfwin
use dflogm
include 'resource.fd'
type (dialog)    dlg
integer          callbacktype
integer          cref
integer          iret

if (callbacktype == dlg_init) then
	! Change the color of the Progress bar to red
	! NOTE:  The following message succeeds only if Internet Explorer 4.0
	!        or later is installed
        cref = #FF	! Red
        iret = DlgSendCtrlMessage(dlg, IDC_PROGRESS1, PBM_SETBARCOLOR, 0, cref)
endif