# Add label to textual data

This question is extremely basic and I know how to solve it basically but it is a workaround and I was wondering whether there is a much better way to do it - here is the problem:

I'd like to give some property (i.e. written text) a label, and I do it like this:

$$\label{12345} \text{\emph{all functions considered are smooth}}.$$


This way I get my desired label - but it is no good if for example the text is rather long ...

-
Check this question: How to link to a label using specific text. –  m0nhawk Dec 17 '12 at 17:34
By "label" here you actually mean the equation number, right? Is that what you want, or do you want some other label? If need be, provide an image of the desired output (even if it's generated in Word). –  Werner Dec 17 '12 at 18:34
@Werner yes, by "label" I mean the equation number, thanks for asking I should have been more clear on this! –  harlekin Dec 17 '12 at 20:49

Normally this is done with the \newtheorem command.

\documentclass{article}
\newtheorem{prop}{Property}

\begin{document}

\begin{prop}
\label{12345}
all functions considered are smooth;
\end{prop}

blah blahh see \ref{12345}
\end{document}

-
thanks for this suggestion, usually I frame my theorems, propositions, lemmas etc in the theorem - environment - here I was rather looking for a version that puts less formal emphasis into the text. –  harlekin Dec 17 '12 at 20:51
the markup should be the same, you can style the prop theorem style however you like, especially if you use a package such as theorem or amsthm that make it easier to make such customisations, so if you don't want a bold heading and just want a number, that can just be a style definition for prop –  David Carlisle Dec 17 '12 at 20:55
true, actually, that'll do the job. many thanks! –  harlekin Dec 17 '12 at 20:59