[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Discovery ... & counter problem



In trying to solve a counter problem (to be discussed below) I made an
interesting discovery: you can set the point size in Xy4 to be zero and then
nothing prints. Well, almost nothing--with  a page of
characters printed as a faint gray, very thin, horizontal line.

This may be printer-specific. I have a HP4-plus printer with LJ4.bin as the
driver.

My problem is this: For the philosophy course I teach, I print out each
class's notes from a long file containing a whole semester of class notes. I
want to put that class's number in the printout, and I'm using counter C5 to
number each class, but I print out each class by defining only that section
of the file, so the printout always interprets "Class " to be "Class 1"
because it is the first C5 in the defined block I'm printing. I use an XPL
program to define the block (it finds the block's start by searching back
from where the cursor is to the first heading it encounters--headings having
a unique string in them.

So the question is: how do I get it to count the 's from the top of the
file? Obviously, I could go to the top of the file and actually search for
all the  "hits," counting as it goes, until it gets to where I started
from, but that's cumbersome. Is there any easier way? E.g., is there a VA
for the C5?

Since this may be hard to visualize, here it is schematically:


Philosophy Class 
text................
Philosophy Class 
text................
***Philosophy Class 
text................***
Philosophy Class 
text................
Philosophy Class 
text................

I want what's between the ***'s to printout as:
Philosophy Class 3
text................

Any ideas?

Thanks,


Harry Binswanger
hb@xxxxxxxx