InputImage Method

[Top]  [Chapter]  [Previous]  [Next]

Applies to



function InputImage(const filename: WideString; Mode: Integer): Integer;


Inserts an image file at cursor position.


See method _SetObjType to convert an embedded image into a special image type which can also store attached data when exported to PDF. This can be useful to add the original source to a PDF file.



The image file, may be BMP, WMF, EMF, JPG or PNG format.


If bit 1 is set the image will be linked, not embedded.

If bit 2 is set the image will be positioned relatively to a paragraph (movable image).

If bit 3 is set the image will be positioned relatively to a page (movable image).

If bit 4 is set text will not wrapp around image (if a movable image).

When bit 5 was set and the image was not found an error text object will be inserted. The error object will display <filename?>.


0 if not successful. Otherwise the interface CurrObj can be used to change image properties.


To create a text box use IWPTextCursor.InputTextbox. (Requires premium license)


Image Support

[idh_iwptextcursor_inputimage.htm]    Copyright © 2007 by WPCubed GmbH