Document Classes ⇒ Caption Package Problem (Miktek >2.5)
Caption Package Problem (Miktek >2.5)
Hi,
I recently updated to Miktek 2.7 (from version 2.5) and have run into an issue using the Caption package - when I try and build my document I get the following error.
! Undefined control sequence.
<argument> ...o }{}\caption@clearsubcontentslines
\g@addto@macro \caption@ty...
1.739 ...Document{\caption@checksubcontentslines}}
! Package caption Error : Something's wrong--perhaps a missing \caption in the last figure or table
I get the error even if I just use an almost empty .tex file i.e. I am figuring it is an issue relating to the style file rather than any of the actual tex files.
Anyone seen this? Anyone got any ideas?? I have googled for solutions/clues without success and am hoping someone will be able to offer a few clues.
Like I say, the document still compiles under MikTek 2.5 (colleague just confirmed this on his XP machine) but I am dealing with a Vista32 machine with a virgin install of MikTek (with all the updates run etc).
Cheers!
I recently updated to Miktek 2.7 (from version 2.5) and have run into an issue using the Caption package - when I try and build my document I get the following error.
! Undefined control sequence.
<argument> ...o }{}\caption@clearsubcontentslines
\g@addto@macro \caption@ty...
1.739 ...Document{\caption@checksubcontentslines}}
! Package caption Error : Something's wrong--perhaps a missing \caption in the last figure or table
I get the error even if I just use an almost empty .tex file i.e. I am figuring it is an issue relating to the style file rather than any of the actual tex files.
Anyone seen this? Anyone got any ideas?? I have googled for solutions/clues without success and am hoping someone will be able to offer a few clues.
Like I say, the document still compiles under MikTek 2.5 (colleague just confirmed this on his XP machine) but I am dealing with a Vista32 machine with a virgin install of MikTek (with all the updates run etc).
Cheers!
NEW: TikZ book now 40% off at Amazon.com for a short time.
- Stefan Kottwitz
- Site Admin
- Posts: 10319
- Joined: Mon Mar 10, 2008 9:44 pm
Re: Caption Package Problem (Miktek >2.5)
Hi kaini,
welcome to the LaTeX Community board!
Verify if you are using an up-to-date version of the caption package, the latest version is 2008/04/01 v3.1h. \caption@clearsubcontentslines is defined inside caption.sty.
Stefan
welcome to the LaTeX Community board!
Verify if you are using an up-to-date version of the caption package, the latest version is 2008/04/01 v3.1h. \caption@clearsubcontentslines is defined inside caption.sty.
Stefan
LaTeX.org admin
Re: Caption Package Problem (Miktek >2.5)
Hi,
Thanks for the prompt reply - just checked the date of the package - package is dated 15/04/2008 on the Package browser - looking at the headers in the caption.sty files it is dated 01/04/2008 v3.1h. So, I think I am using the latest.
Any other ideas?

Thanks for the prompt reply - just checked the date of the package - package is dated 15/04/2008 on the Package browser - looking at the headers in the caption.sty files it is dated 01/04/2008 v3.1h. So, I think I am using the latest.
Any other ideas?

- Stefan Kottwitz
- Site Admin
- Posts: 10319
- Joined: Mon Mar 10, 2008 9:44 pm
Re: Caption Package Problem (Miktek >2.5)
Hi kaini,
could you post your logfile as attachment? Perhaps we get an idea by reading it looking for errors, warnings, messages.
Stefan
could you post your logfile as attachment? Perhaps we get an idea by reading it looking for errors, warnings, messages.
Stefan
LaTeX.org admin
Re: Caption Package Problem (Miktek >2.5)
Hi again,
Logfile attached as requested (just one note: I have just been trying MikTek 2.6 to see if it was any different from 2.7 - hence the notes in logfile which reference 2.6 - behaviour with 2.7 is identical).
Many thanks
Logfile attached as requested (just one note: I have just been trying MikTek 2.6 to see if it was any different from 2.7 - hence the notes in logfile which reference 2.6 - behaviour with 2.7 is identical).
Many thanks
- Attachments
-
- logfile.txt.log
- (10.51 KiB) Downloaded 383 times
- Stefan Kottwitz
- Site Admin
- Posts: 10319
- Joined: Mon Mar 10, 2008 9:44 pm
Re: Caption Package Problem (Miktek >2.5)
I've read the logfile but it's still enigmatic because that control sequence should be defined. I've seen you use the subfigure package, that package is outdated an not well supported by caption. As the error message concerns commands dealing with subcaptions, it may be worth a try to compile it without loading subfigure.
Stefan
Stefan
LaTeX.org admin
Re: Caption Package Problem (Miktek >2.5)
Hi Stefan,
Thanks for the continued help - have commented out the subfigure package as you suggest and still have the same issue - log file attached again.
Hope you are not running out of ideas; as I have to confess I have
Cheers
Thanks for the continued help - have commented out the subfigure package as you suggest and still have the same issue - log file attached again.
Hope you are not running out of ideas; as I have to confess I have

Cheers
- Attachments
-
- log.txt.log
- (9.86 KiB) Downloaded 370 times
- Stefan Kottwitz
- Site Admin
- Posts: 10319
- Joined: Mon Mar 10, 2008 9:44 pm
Caption Package Problem (Miktek >2.5)
Could you post a minimal working example (with your preamble) that produces this error and is compilable? I would test it with my LaTeX installation.
Stefan
Stefan
LaTeX.org admin
Re: Caption Package Problem (Miktek >2.5)
Hi,
Have attached essentially an empty tex top level - and associated style file - this combination still causes the issue we have been discussing.
Cheers
Have attached essentially an empty tex top level - and associated style file - this combination still causes the issue we have been discussing.
Cheers
- Attachments
-
- ISLIthesis-v1.cls
- (16.28 KiB) Downloaded 413 times
-
- MWE.tex
- (3.35 KiB) Downloaded 394 times
- Stefan Kottwitz
- Site Admin
- Posts: 10319
- Joined: Mon Mar 10, 2008 9:44 pm
Caption Package Problem (Miktek >2.5)
Hi kaini,
I've found the problem. It's caused inside the class file ISLIthesis-v1.cls: line 198/199:
caption should be loaded before \begin{document}. Just move this line 199 to the end of the class file or remove it and load caption with \usepackage inside your document.
Stefan
I've found the problem. It's caused inside the class file ISLIthesis-v1.cls: line 198/199:
Code: Select all
\AtBeginDocument{
\RequirePackage[hang]{caption}
Stefan
LaTeX.org admin