Notifications - Adobe 65030365 - FrameMaker - PC Manual

Scripting guide
Hide thumbs Also See for 65030365 - FrameMaker - PC:
Table of Contents

Advertisement

ADOBE FRAMEMAKER SCRIPTING GUIDE
Differences between scripts and FDK

Notifications

Notifications is the internal mechanism through which a script registered for a particular event is run when the event
is triggered.
As an example, consider the following script:
/*
Sample script to demonstrate how to use notification mechanism of FrameMaker though
ExtendScript
*/
/*
There are basically two parts to a notification script.
1. Registering for a desired notification. (This is done by calling 'Notification()' with
desired notifications as argument.)
2. Implement a handler for these notifications in your script. ( Implement 'Notify()' in
script)
*/
/*
Part 1. Registering for Notifications
Notification()' is a global function and is available readily in scripting. (Similar to
F_ApiNotification())
The Syntax for Notification() is: Notification(int, int,.....,int, bool);
it takes:
a.) list of notifications(FA_Note_preOpenDoc, FA_Note_PostOpenDoc etc.) and
b.) param bool: true = register for provided notification list, false = unregister for provided
notification list.
(This parameter is optional and by default 'true')
Note: for more details please see F_ApiNotification() in FDK reference guide.
*/
/*
Notification(FA_Note_PreOpenDoc,true);
This is same as Notification(FA_Note_PreSaveDoc)
or you can register for more than one notification at once
Notification(FA_Note_PostOpenDoc,FA_Note_PreSaveDoc);
Here we register for the notification: FA_Note_PostOpenDoc - this notification is
triggered just after a document is opened.
Notification(FA_Note_PostOpenDoc,true);
*/
/*
Part 2: handler
This can be done by implementing function 'Notify()' that are called by FrameMaker when any
Last updated 9/26/2011
11

Advertisement

Table of Contents
loading

This manual is also suitable for:

Framemaker 10

Table of Contents