I want to use sub-numbering for certain theorems. I used the solution provided in the question How do I get sub-numbering for theorems (Theorem 1.A., Theorem 1.B., Theorem 2.)?, which does exactly what I want.

However, there seems to be an issue with hyperref. Upon compilation I get a warning

destination with the same identifier (name{theorem1.1}) has already been used, duplicate ignored < to be read again > relaxl.197 (...)

The output pdf document is fine, except that when using a \ref to a "subtheorem", clicking on the output hyperlink sends to the wrong theorem (in my case it links to Proposition 1.2 instead of Theorem 19.B).

I would be grateful if anyone knows how to fix this or suggest an alternative.

  • Can you please add a full minimal working example so that people can see what packages etc you need to get your code to work (but don't add code that is not needed). This makes it much easier for people to help you.
    – user30471
    Feb 28, 2015 at 3:55
  • @Andrew: I was about to add a full minimal working example as you rightly requested, but then there was already a posted answer which solves my problem perfectly.
    – Seub
    Feb 28, 2015 at 5:01

1 Answer 1


You need to also adjust the H-style counter associated with thm:

enter image description here


  \protected@edef\theparentnumber{\csname the#1\endcsname}%
  \expandafter\def\csname the#1\endcsname{\theparentnumber.\Alph{#1}}%
  % To keep hyperref happy, update H-counter as well
  \expandafter\def\csname theH#1\endcsname{thm.\theparentnumber.\Alph{#1}}%




Two, first part

Two, second part


\ref{thm:one}, \ref{thm:two}, \ref{thm:twoA}, \ref{thm:twoB}, \ref{thm:three}.


Note the addition of \unskip as well, to avoid spurious vertical spacing at the start of the subtheorem environment.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .