Dekel Tsur wrote:
> 
> On Wed, Jun 13, 2001 at 09:31:35AM +0200, Juergen Vigna wrote:
> >
> > On 08-Jun-2001 Fernando Pérez wrote:
> >
> > > Great tip, and  thanks! I was having the same problem and thought it was a
> > > lyx 1.1.6 bug (knowing there are problems with tabular stuff). Now it
> > > works. However, I still think it's a "minibug", since its behavior is
> > > inconsistent with that of Figures: in 1.1.6 figure floats still work the
> > > old way:
> >
> > Obviously if this behaviour creates "LaTeX errors" then it is wrong!
> > I'll have a look on this!

it is wrong!

> You need to put \protect before fragile command (\begin, \end, \\, \hline)
> in moving argument.
> However, I just tried creating a tabular in a caption using ERT, and I still
> get errors due to \hline commands. Does anyone know what is the solution ?

no problem, when you define the table outside the float. this can be
just before this one.

\newcommand\myTable{% 
 \begin{tabular}{|c|c|}\hline
  a & b \\\hline  
  c & d\\\hline
 \end{tabular}%
}

... the float ...
\caption{a very nice caption with a nice \protect\myTable}

Herbert

-- 
http://www.educat.hu-berlin.de/~voss/lyx/

Reply via email to