qbd software ltd [UK]
qprinter > moth > qbd software
qPrinter² qcDocument: Properties and Methods
Applies To:
qcDocument
 
See Also:
AbsoluteItems
DocumentItems
AddBankImage
 

AddImage

Adds an Image to the Document collection. An Image can be added from another object, a file or from the ImageBank.

Syntax

Object.AddImage (bAbsolute As Boolean, PictureFromObject As StdPicture, LoadFileName As String, ImageBankKey As String , bVAlignNextItem As Boolean , sKey As String, BeforeObject As Variant, AfterObject As Variant)

Parameters
bAbsoluteSets whether the Item is Absolute - appearing on a specified page at a specified position, or TextFlow where the position is dependent on the other Items in the Document.
PictureFromObjectAdd a picture from a object e.g. PictureBox, Form or Image.
LoadFileNameThe filename of an Image to load.
ImageBankKeyThe Key identifying an Image already added to the ImageBank.
bVAlignNextItemThe Vertical Alignment of the Item. When set to True the Top of the next item in the Document will be at the same vertical position as this Item.
sKeyThe Key to identify the Item.
BeforeObjectThe Index or Key of the Item the new Item should be placed before in the Document order.
AfterObjectThe Index or Key of the Item the new Item should be placed after in the Document order.

Notes

Only one item is required for either the PictureFromObject, LoadFileName or ImageBankKey. The ImageBank can be used for repeated images to lower the amount of resources the document uses.

Example

' Add an image from an Object
qPrint.Document.AddImage False, Picture1.Picture
' Add an image from a File
qPrint.Document.AddImage False, , "C:\My Documents\Picture.bmp"

' Add an image to the ImageBank
qPrint.Document.AddBankImage "Image1", Picture1.Picture
' Add an image to the document from the ImageBank
qPrint.Document.AddImage False, , , "Image1" 

See Also: AbsoluteItems, DocumentItems, AddBankImage

©2002 qbd software ltd