Hans Hagen schrieb am 14.01.2020 um 09:58:
On 1/13/2020 10:01 PM, Wolfgang Schuster wrote:
Hi,
I try to get the counter value of the next section but the result is always the value for the current section (e.g. section 3 shows also 3 as value for the next section).
\startbuffer[headnumber] \starttabulate \NC first \EQ \somenamedheadnumber {section} {first} \NC\NR \NC previous \EQ \somenamedheadnumber {section} {previous} \NC\NR \NC current \EQ \somenamedheadnumber {section} {current} \NC\NR \NC next \EQ \somenamedheadnumber {section} {next} \NC\NR \NC last \EQ \somenamedheadnumber {section} {last} \NC\NR \stoptabulate \stopbuffer
\starttext
\dorecurse{5} {\section{Section #1} \getbuffer[headnumber]}
\stoptext Also in a second run?
Yes, only first and last are correct but previous and next show always the number of the current section. Wolfgang