[...file opened...]
set F to 101
call("outputpage")
set F to 102
call("outputpage")
[...file closed...]
terminate()
.outputpage
selectframe(F)
set B to status(frames)
if (B = 0) appendframe(F)
if (B ! 0) appendframes(F)
return()
What will happen, is...
Set 'F', our frame number, to 101.
Call 'outputpage'.
Outputpage: Select the given frame, in this case 101.
Outputpage: Are there any subframes?
Outputpage: If there are NO subframes, write the frame to the file.
Outputpage: If yes, write the frames (all of them) to the file.
Outputpage: Return to caller.
Set 'F', our frame number, to 102.
Call 'outputpage'.
Outputpage: Select the given frame, in this case 102.
Outputpage: Are there any subframes?
Outputpage: If there are NO subframes, write the frame to the file.
Outputpage: If yes, write the frames (all of them) to the file.
Outputpage: Return to caller.