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

Applies to



int InputEmbeddedData( string imagefilename,  int Mode,string datafilename, string dataparams, int datamode);


This method can be used to create a certain object which can also hold binary data. The binary data will be embedded into a PDF file when the internal PDF creation (optional feature) is used.


It is not possible to change the image later using IWPTextObj.LoadFromStream and IWPTextObj.LoadFromFile, these methods will update the attached data, not the image. The method Contents_LoadFromFile however will update the image data.





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


You can also use "pin", "graph", "tag" and "clip" to create an icon. The icon will be only displayed by Acrobat Reader after the export to PDF.


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 wrap 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?>.


The file name of the data to be attached


Optional parameter list. You can use the parameter names contents and title.

Example: "\"Contents=this is hint text\",\"Title=Headline for the hint window\""


should be 0


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


C# Example





   "C:\\my document.rtf",

   "\"Contents=this is hint text\",\"Title=Headline for the hint window\"",


Display in AcrobatReader



You can load data from a stream in this object by using CurrObj.LoadFromStream


System.IO.Stream str = new System.IO.MemoryStream();


   new WPDynamic.Stream2WPStream(str) ,false,"RTF");


   new WPDynamic.Stream2WPStream(str));






[iwptextcursor_inputembeddeddat.htm]    Copyright © 2007 by WPCubed GmbH