Inserts a bitmap at the insertion point in a RichTextEdit control.
RichTextEdit controls
rtename.InsertPicture ( filename )
Argument |
Description |
---|---|
rtename |
The name of the RichTextEdit control in which you want to insert a picture |
filename |
A string whose value is the name of the file that contains the bitmap |
Integer. Returns 1 if it succeeds and -1 if an error occurs. If filename is null, InsertPicture returns null.
If there is a selection, InsertPicture inserts the bitmap at the beginning of the selection. The bitmap and the selection remain selected.
This example inserts a BMP file at the insertion point in the RichTextEdit control rte_1:
integer li_rtn
li_rtn = rte_1.InsertPicture("c:\windows\earth.bmp")