I would like to have my Table counting like

Table P1.1
Table P1.2
Table P1.3

I tried with \renewcommand{\thetable}{P1.???}, and I do not know what to put on the question marks.

EDIT I wrote this code

\setcounter{figure}{0} \begin{figure}[htbp!] \includegraphics[scale=0.5]{Figures/P1.1.png} \caption{\label{fig:P1.1}When reading from a scale, make sure that you know what each division on the scale represents.} \end{figure}

and I would like that my figure/table have enter image description here

Figure P1.2.png instead of P1.16.2 after using this

\let\oldthetable\thetable \renewcommand{\thetable}{P1.\oldthetable} \let\oldthefigure\thefigure \renewcommand{\thefigure}{P1.\oldthefigure}

  • Welcome to tex.se! An MWE or some minimal code that explains your problem is always appreciated. Could you clarify what you want?
    – Jes
    Mar 12, 2021 at 23:38
  • 1
    In P1.2, what does P1 (or possible P and 1, individually) and 2 represent?
    – Werner
    Mar 12, 2021 at 23:39
  • @Werner ,,P1`` for ,,part 1``, perhaps?
    – chsk
    Mar 13, 2021 at 9:40

2 Answers 2


It depends on what the components of your figure/table number represent what you need to do. Here are some options:

  1. P1 is just a prefix and has no connection to anything within your document.

  2. P1 refers to \part one of your document, and is therefore tied to parts.

  3. In a numbering that resembles P1.16.2, the 16 represents either a chapter (in the book or report class, or something similar that provides \chapter) or a section (in article, or something similar that doesn't provide \chapter); the former is more common than the latter. For this option you'll have to allow your figure/table numbering to be continuous across these document elements (see Continuous v. per-chapter/section numbering of figures, tables, and other document elements) in addition to updating the counter representation:

    % Continuous figure/table numbering: https://tex.stackexchange.com/q/28333/5764
    \counterwithout{figure}{chapter}% or \counterwithout{figure}{section}
    \counterwithout{table}{chapter}% or \counterwithout{table}{section}

The easiest way I can think of doing this is simply reusing whatever \thetable was before:

        Test 1\caption{Test 1}\label{tab:test1}
        Test 2\caption{Test 2}\label{tab:test2}
        Test 3\caption{Test 3}\label{tab:test3}

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.