# (Beamer) Numbering captions by section in beamer

I'm writing-up a lecture course in Latex with an essentially identical set of slides in beamer. I'd like to have the figure numbering in the beamer slides to match those of the lecture notes, for the sake of consistency in cross-referencing.

The lecture notes are written in the article document style (in particular there are no chapters), and have figures numbered by section (i.e. `\section`.`\figure`). Is there some simple preamble-trick or workaround that will change the way that the captions are produced in beamer to number them consistently with the lecture notes?

I'm trying to avoid having to write a new macro to use in the main body, since I'm compiling the notes and slides from the same set of source-files using `\input`.

-

``````\setbeamertemplate{caption}[numbered]
The second line declares that the `figure` counter is subordinate to the `section` counter, so resets for each new `\section` and labels figures 1.1, 1.2, ..., 2.1, 2.2, .... This is built into LaTeX.