1

I just reinstalled my MikTeX 2.9, and am getting this following error message:

! LaTeX Error: Command \counterwithin already defined.
               Or name \end... illegal, see p.192 of the manual.

I saw the following line of questions in this link: ! LaTeX Error: Command \counterwithout already defined but it doesn't seem to be my problem, as I checked and the chngctr version is 1.1a. Is there something else I'm missing?

Here is my MWE:

\documentclass[oneside]{memoir}
\let\counterwithout\relax
\let\counterwithin\relax
\usepackage{chngcntr}

\begin{document}

\frontmatter

This information is duplicated directly from the Blahblah.  

%The above is necessary in order to display the subsections in the TOC.
\tableofcontents
\mainmatter
    lalalal

\end{document}

closed as off-topic by Mensch, Stefan Pinnow, Sebastiano, user121799, user156344 Apr 1 at 4:37

  • This question does not fall within the scope of TeX, LaTeX or related typesetting systems as defined in the help center.
If this question can be reworded to fit the rules in the help center, please edit the question.

  • Mine MikTeX 2.9 compiles it without errors, even with \let lines commented. – Przemysław Scherwentke Sep 7 '18 at 1:59
  • 1
    Maybe you have a local version of chngcntr.sty that takes precedence over the version you checked. Have a look at the .log file to find out where the chngcntr.sty is found and what its version is. – moewe Sep 7 '18 at 4:50
  • @moewe, thank you, I looked at my .log file and this is the only line that references chngcntr: "Package chngcntr [2008/07/23] emulated by memoir. " Is this my problem? – sml Sep 7 '18 at 5:46
  • 2
    Check logs for local copies of memoir, check the path for memoir. It probably says app data, and thus was not deleted when you reinstalled miktex. Remember miktex (confusingly) installs in two places, system and user. The latter takes precedence, this is why every time you update miktex you have to update as user and admin, or you end up with old user versions overwriting new system versions. – daleif Sep 7 '18 at 6:14
  • 4
    I'm voting to close this question as off-topic because after a reinstallation mentioned in comments the issue vanished. – Mensch Mar 31 at 18:58

Browse other questions tagged or ask your own question.