I want to export my figures for an editor for import in another text editing program. I would like to have the name of the file correspond to the figures in the document. In the document they start with one but the export functionality of pgf adds a 0. The documentation says:

Changes the names of all following figures. It is possible to change figure name during the document either using \tikzset{external/figure name={⟨name⟩}} or with this command. A unique counter will be used for each different {⟨name⟩}, and each counter will start at 0.

I tried to define the picture name and increase the counter, but the counter seems to have a different name:


LaTeX complains:

! LaTeX Error: No counter 'mueller-abbildung-' defined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.

l.131 ...nter{mueller-abbildung-}{1}
  • There is no counter. The value is stored in a macro. But without a minimal example it is not possible to test if, how and where one could change the start value. Oct 29 '13 at 14:18

It is not a real TeX counter. It holds the value and uses the \tikzexternal@getnextfilename@advancecount macro to step up. So it's normal that you can't find it.

Adding in the last part of the preamble the following

\expandafter\gdef\csname c@tikzext@no@\pgfkeysvalueof{/tikz/external/figure name}\endcsname{1}%

should solve it (untested in the absence of a MWE).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.