
438
ADOBE FRAMEMAKER SCRIPTING GUIDE
Function Summary
Last updated 9/26/2011
Returns
int
Syntax
UpdateBook(updateParams, updateReturnParams)
Parameters
Import
Description
The
Import()
method imports text or graphics into a document.
Import()
allows you to specify a script (property list) specifying how to import text or graphics and how to deal with
error and warning conditions.
For example, you can specify whether to import a file by reference or by copy.
If you import a file by reference,
Import()
creates an inset. The following list summarizes the types of files you can
import with
Import()
and the types of inset objects it creates when you import them by reference:
•
Graphics - FO_Inset
•
Text - FO_TiText, FO_TiTextTable
•
Frame binary document - FO_TiFlow
•
MIF - FO_TiFlow
Note:
When importing a graphic, you can specify that it be imported at its default resolution by setting the
Constants.FS_GraphicDpi (15)
property to 0 and setting the
Constants.FS_FitGraphicInSelectedRect (14)
property to
False
. If the graphic has no default resolution, it is imported at 72 dpi
To get a property list to specify for the
importParamsp
parameter, use
GetImportDefaultParams()
or create the list
from scratch.
Note:
Always initialize the pointer to the property list that you specify for
importReturnParamspp
to null before you
call
Import()
.
The following are the list of properties that can be imported:
Parameter name
Data Type
Optional
Description
updateParams
PropVals
No
A property list specifying how to update the book and how to
respond to errors and other conditions. To use the default list,
specify
null
.
updateReturnParams
PropVals
No
A property list that provides information about how the
FrameMaker product updated the book. This parameter must be
initialized before you call
UpdateBook()
.
Property
Meaning
Constants.FS_AlertUserAboutFailure (2)
Alert user if an unexpected condition, such as an unrecognized file type, occurs. Set to either
True or False
•
True - Notify user when unexpected conditions occur.
•
False - Do not notify user when unexpected conditions occur.