From: Thomas Engel <thomas.engel1@gmx.net>
Subject: store counter or variable and reread again
Date: Sat, 30 Dec 2006 16:51:09 +0100 [thread overview]
Message-ID: <45968AED.7040904@gmx.net> (raw)
In-Reply-To: <459670F8.5020106@elvenkind.com>
Hello,
i just playing a little bit with macros.
For adding points to a total sum i use this macros
\global\newcount\summeP \summeP=0
% ad the points of each question
\def\getPunkte[#1]{\global\advance\summeP by \number#1}
% show the points on the right side
\def\showP[#1]{\inright{\hskip 10mm \framed{#1} }}
% handle the points
\def\pkt[#1]%
{\showP[#1]%
\getPunkte[#1] }
this is working well but my problem is I want to use \summeP on the
first page to show the total amount of points for the whole exam.
I know that this needs a second run of texexec, but I don't know how to
store the value at the end of the file and reread this stored value in a
second run the get the right value.
Any hints are welcome!
Thanks and a Happy New Year!
Thomas
next prev parent reply other threads:[~2006-12-30 15:51 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <45941026$0$4168$ba624c82@nntp02.dk.telia.net>
2006-12-30 14:00 ` Week number Taco Hoekwater
2006-12-30 15:51 ` Thomas Engel [this message]
2006-12-30 16:56 ` store counter or variable and reread again Aditya Mahajan
2006-12-30 19:19 ` Peter Münster
2006-12-30 21:30 ` Aditya Mahajan
2006-12-30 22:35 ` Hans Hagen
2006-12-30 23:19 ` Aditya Mahajan
2006-12-30 23:51 ` Aditya Mahajan
2006-12-31 8:21 ` Thomas Engel
2006-12-31 17:52 ` Aditya Mahajan
2007-01-01 22:28 ` Hans Hagen
2007-01-01 8:11 ` Peter Münster
2007-01-01 11:17 ` Aditya Mahajan
2007-01-01 15:35 ` Peter Münster
2007-01-01 22:14 ` Hans Hagen
2007-01-02 18:38 ` Peter Münster
2007-01-04 16:43 ` Hans Hagen
2006-12-30 21:34 ` Week number Aditya Mahajan
2006-12-30 22:28 ` Hans Hagen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=45968AED.7040904@gmx.net \
--to=thomas.engel1@gmx.net \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).