msgs12.hlp (Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
MLM_QUERYSELTEXT (1.2)
Message Group  Overview                           Up Next Previous
────────────────────────────────────────────────────────────────────────────
 
#define INCL_WINMLE
 
MLM_QUERYSELTEXT
mp1 = MPFROMP((PCH) pchBuf);   /* pointer to buffer for selection */
mp2 = 0L;                      /* not used, must be zero          */
 
An application sends an MLM_QUERYSELTEXT message to copy the selection from
a multiple-line entry field (MLE) into the specified buffer.
 
Parameter  Description
────────────────────────────────────────────────────────────────────────────
 
pchBuf     Low and high word of mp1. Points to the buffer that receives the
           selected text.
 
Return Value
 
The return value is a 32-bit value (ULONG) that specifies the number of
bytes actually placed in the buffer.
 
Comments
 
The application must ensure that the selected text does not overflow the
buffer. An application can send an MLM_QUERYSEL message to retrieve
character offsets of the selection and then send an
MLM_QUERYFORMATTEXTLENGTH message to determine the number of bytes the
selected text occupies.
 
See Also
 
MLM_QUERYFORMATTEXTLENGTH, MLM_QUERYSEL