I don't understand why I can't have a caption here:
\begin{table}[H]
\begin{tabular}{cc}
\hline
\textbf{Ejemplo 3} & \includegraphics[width=8cm,height=4cm]{figura/07.jpg} \\
\includegraphics[width=6cm,height=4cm]{figura/07_1.jpg} & \includegraphics[width=6cm,height=4cm]{figura/07_2.JPG} \\
\hline
\textbf{Foto 7} & \includegraphics[width=8cm,height=4cm]{figura/48.jpg}\\
\includegraphics[width=6cm,height=4cm]{figura/48_1.jpg} & \includegraphics[width=6cm,height=4cm]{figura/48_2.JPG}\\
\hline
\label{casosop2}
\end{table}
\caption{caption}
\end{tabular}
I get the following error:
! Missing \endgroup inserted.
<inserted text>
\endgroup
l.84 \end{table}
If I remove the caption line, I get no problems.

\end{tabular}and\end{table}are the wrong way around. You should have\end{tabular}first and then\end{table}. Anyway, I understand that you're frustrated, but please don't pepper your post with multiple exclamation marks etc. we don't like being shouted at and in any case Stackexchange sees itself as an encyclopaedic knowledge base, rather than a help group or anything – Au101 Mar 19 '16 at 05:29