Adding text to a FrameMaker document and enabling change bar

The following script adds a sample text to a FrameMaker document and then enables the change bar. Open a FrameMaker document before running the script.

Copy and paste the script to ESTK and select FrameMaker 10 as the target application. Click the Play button to run the script.

var doc = app.ActiveDoc 
var tl = new TextLoc() 
var firstPgf = doc.MainFlowInDoc.FirstTextFrameInFlow.FirstPgf 
tl.obj = firstPgf 
doc.AddText (tl, "Hello") 
doc.AutoChangeBars =1;

The script creates a text location using the new TextLoc() method. Assign the first page of the document as the text location. Using the AddText() method, add a sample text. Set the AutoChangeBars property to 1 to enable the change bar.

// Ethnio survey code removed