BCGControlBar Pro for MFC
virtual BOOL CBCGPEditCtrl::InsertText ( LPCTSTR  lpszText,
int  nInsertFrom = -1,
BOOL  bRedraw = FALSE,
BOOL  bSuppressUndo = FALSE,
BOOL  bUpdateLineData = TRUE,
BOOL  bForceNextUndo = FALSE,
BOOL  bAlwaysAtEnd = TRUE 
)
virtual

Inserts text into the edit control at specified position.

Returns
Nonzero if the function succeeds; otherwise 0.

Use this function to insert a new text into the edit control at specified by nInsertFrom position. If nInsertFrom is -1 the text will be inserted at the current caret position.

The text is placed in undo buffer unless you set bSuppressUndo to TRUE. In this case the text is not placed in the undo buffer and the undo buffer is cleared.

Parameters
lpszTextPoints to a text string to insert.
nInsertFromSpecifies the insert position (offset from the beginning of the existing text).
bRedrawSpecifies whether the edit control should be redrawn (TRUE) or not (FALSE).
bSuppressUndoIf TRUE, the inserted text is not placed in the undo buffer and the undo buffer is cleared.
bUpdateLineDataSpecifies whether the line-related data (markers) should be updated or not.
bForceNextUndoSpecifies whether the undo action, created as a result of deletion, should be used as a complex undo action in sequence.
bAlwaysAtEndIf TRUE, the inserted text will be added to the end of the existing text.