Jump to content

MLM INSERT

From EDM2
Revision as of 04:32, 25 April 2025 by Martini (talk | contribs) (Created page with "This message deletes the current selection and replaces it with a text string. ==Syntax== <pre> param1 PCHAR pchText; Null-terminated text string.: param2 ULONG ulReserved; Reserved value, should be 0.: </pre> ==Parameters== ;pchText (PCHAR) - input: Null-terminated text string. ;ulReserved (ULONG) - input: Reserved value, should be 0. ==Returns== ;ulCount (ULONG) - return: Number of bytes actually inserted. ==Remarks== This message inserts the...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This message deletes the current selection and replaces it with a text string.

Syntax

param1
PCHAR pchText;   /* Null-terminated text string. */

param2
ULONG ulReserved;  /* Reserved value, should be 0. */

Parameters

pchText (PCHAR) - input
Null-terminated text string.
ulReserved (ULONG) - input
Reserved value, should be 0.

Returns

ulCount (ULONG) - return
Number of bytes actually inserted.

Remarks

This message inserts the text string at the current selection, deleting that selection in the same manner as typing at the keyboard would. The text string must be in CF_TEXT format (or one of the formats acceptable to MLM_IMPORT) and null- terminated. The line-break (CR LF, LF, and so on) is counted as one byte, regardless of the number of bytes occupied in the buffer, and the null terminator is not counted.

This interacts with the format rectangle and text limits, and a return of less than the full count can be the result. If so, a notification message is sent.

Default Processing

The default window procedure takes no action on this message, other than to set ulCount to 0.