TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I use memoir class, I get an error message file ended when scanning \makechapterstye

This is what I want. I get the code from "Variation over VZ39, contributed by Danie Els, Various chapter styles for the memoir class" by LarsMadsen

Can anyone help me please? This is the code :

\usepackage{fourier} % or what ever
\usepackage[scaled=.92]{helvet}%. Sans serif Helvetica
\leavevmode\leaders\hrule height 1\p@ \hfill \kern \z@}
\makebox[0pt][c]{#1\strut} \\[.5ex]
\chaptitlefont ##1\par}}%

Error message : File ended while scanning use of \makechapterstyle.

share|improve this question
You should add an example of your LaTeX code. – egreg Sep 4 '11 at 9:33
I have added the code egreg, Thanks you. – Verly Sep 4 '11 at 9:55
up vote 5 down vote accepted

You're missing the closing brace in the last \parbox first argument, but as it is it means nothing:


isn't a dimension. What you probably want is


You need also to change the code in \BuildChpNum:

    \makebox[0pt][c]{#1\strut} \\[.5ex]

Using a \rule to get a horizontal space is quite strange; moreover the two 1ex are different, as the first is from \normalfont and the second is from \bfseries. Adjust the 6pt to something that pleases you.

share|improve this answer
Thanks egreg, you're right . with this all running well : \parbox[t]{\hsize-\wd\ChpNumBox-1em}{% – Verly Sep 4 '11 at 12:08

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.