Part of the Samples Website. 8/16/97.

samples.basicStuff.exportFromOutline

«Exports a list of objects contained in an outline
on exportFromOutline (adroutline, folder)
«adrOutline is the address of a Frontier outline object
«make it the target, assume the cursor is on a line that contains several subheads
«each subhead contains the address of an object that we want to export
«folder is the folder that will contain the exported objects
«I keep my export list as a suboutline in my Notepad.
«I also keep change notes under the items, so the outline serves a dual purpose.
«Onward!
«Thu, Sep 19, 1996 at 7:42:21 AM by DW
file.sureFolder (folder)
target.set (adroutline)
op.expand (1)
if not op.go (right, 1)
scriptError ("The cursor headline has no subheads.")
loop
if not script.isComment () «allow comment lines
local (adr = address (op.getLineText ()))
local (fname = nameOf (parentOf (adr^)^) + "." + nameOf (adr^))
msg (fname)
export.sendObject (adr, folder + fname)
file.setmodified (folder + fname, timeModified (adr^))
if not op.go (down, 1)
break
op.go (left, 1)
return (true)
bundle «test code
exportFromOutline (@people.dw.notepad, "Macintosh HD:New Releases:DW 4.1 Endgame:")


This page was last built on Sat, Aug 16, 1997 at 6:35:12 PM. You can download the current set of sample scripts from our FTP site. Dave