2

I like to add chapter names in my header. Currently I used this command

 \fancyhead[RO,LE]{Chapter \thechapter}

which can only show the chapter number . How can I add names instead of numbers.

  • 2
    Try \fancyhead[RO,LE]{\leftmark}. If that does not help, please show us a minimal working example. – Johannes_B Jun 9 '15 at 11:15
  • Do you mean adding the chapter title? – Bernard Jun 9 '15 at 11:15
  • Try this: Create \newcommand\myChapterTitle{}. At the beginning of each chapter, \renewcommand\myChapterTitle{whatever it is}. Then, in your heading, use \myChapterTitle instead of \thechapter. – RobtA Jun 10 '15 at 1:24
  • yeah , \leftmark is working fine for me – botguide Jun 12 '15 at 3:23
1

\fancyhead[RO,LE]{\leftmark} should do what you want.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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