共用方式為


ForeignData Element

Contains a MIME (Multipurpose Internet Mail Extensions) encoded BLOB of picture data, such as Windows metafile, bitmap, or OLE data.

Syntax

<ForeignData
    ForeignType
    [ObjectType]
    [ShowAsIcon]
    [ObjectWidth]
    [ObjectHeight]
    [MappingMode]
    [ExtentX]
    [ExtentY]
    [CompressionType]
    [CompressionLevel]>
</ForeignData>

Attributes

ForeignType

Required string.

Value

Description

MetaFile

MetaFile

EnhMetaFile

Enhanced Metafile

Bitmap

Bitmap

Object

Object

Ink

Ink

ObjectType

Optional int. If the ForeignType attribute is "Object", the ForeignData element must also have an ObjectType attribute. The ObjectType attribute is an integer value that may be a sum of the following values.

Value

Description

256

Linked object

512

Embedded object

1024

Control

16384

OLE2 Named

32768

OLE2 object

ShowAsIcon

Optional Boolean. This attribute is only meaningful if the foreign data is an OLE2 embedded object.

Value

Description

0

Do not show embedded data as an icon.

1

Show embedded data as an icon.

ObjectWidth

Optional float. This attribute is only meaningful if the foreign data is an OLE2 embedded object. The value expresses the width of the object in page units.

ObjectHeight

Optional float. This attribute is only meaningful if the foreign data is an OLE2 embedded object. The value expresses the height of the object in page units.

MappingMode

Optional int. This attribute is only meaningful if the foreign data is a metafile. The value indicates the metafile mapping mode.

ExtentX

Optional float. This attribute is only meaningful if the foreign data is a metafile. The value indicates the horizontal extent of the metafile.

ExtentY

Optional float. This attribute is only meaningful if the foreign data is a metafile. The value indicates the vertical extent of the metafile.

CompressionType

Optional string. This attribute is only meaningful if the foreign data is a raster-based foreign object, such as a DIB, JPG, PNG, TIFF, or GIF file. The value indicates the type of compression applied to the file.

Value

Description

None

No compression (the default)

JPEG

JPEG compression

GIF

GIF compression

TIFF

TIFF compression

PNG

PNG compression

CompressionLevel

Optional float. This attribute is only meaningful if the foreign data is a raster-based foreign object, such as a DIB, JPG, PNG, TIFF, or GIF file. The value indicates the level of compression applied to the file. Compression level is measured in hundredths of a percent.

Element properties

Property

Value

Name

ForeignData

Minimum Occurrences

0

Maximum Occurrences

1

Element information

Parent elements

PageSheet

Shape

StyleSheet

DocumentSheet

Child elements

None

See also

ForeignData property

ForeignType property