LaTeX forum ⇒ GeneralCommand 'caption@box' Topic is solved

LaTeX specific issues not fitting into one of the other forums of this category.
mimi04
Posts: 12
Joined: Tue Sep 03, 2019 1:17 pm

Command 'caption@box'

Postby mimi04 » Thu Sep 05, 2019 12:24 am

Stefan Kottwitz wrote:Do you have a file caption.sty in your document directory? If yes, then delete it or rename it. Seems there is an old version. From the .log file:

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. (caption.sty
  2. Package: caption 2012/02/19 v3.2f Customizing captions (AR)
  3.  
  4. ("C:\Users\...\AppData\Local\Programs\MiKTeX 2.9\tex/latex/caption\caption3.sty
  5. "
  6. Package: caption3 2018/09/12 v1.8c caption3 kernel (AR)


First, a current caption package would print "Package: caption 2019/09/01 v3.3d Customizing captions (AR)". Second, there is no C:\Users\...\AppData\Local\Programs\MiKTeX 2.9 path for caption.sty.

Stefan


That's great, the problem it s disappeared after your advices Mr Stefan thank you, now it rest other Error but can't find it where exactly!!
Attachments
PICTURE0.PNG
PICTURE0.PNG (32 KiB) Viewed 926 times

mimi04
Posts: 12
Joined: Tue Sep 03, 2019 1:17 pm

Postby mimi04 » Thu Sep 05, 2019 1:10 am

Stefan Kottwitz wrote:Do you have a file caption.sty in your document directory? If yes, then delete it or rename it. Seems there is an old version. From the .log file:

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. (caption.sty
  2. Package: caption 2012/02/19 v3.2f Customizing captions (AR)
  3.  
  4. ("C:\Users\...\AppData\Local\Programs\MiKTeX 2.9\tex/latex/caption\caption3.sty
  5. "
  6. Package: caption3 2018/09/12 v1.8c caption3 kernel (AR)


First, a current caption package would print "Package: caption 2019/09/01 v3.3d Customizing captions (AR)". Second, there is no C:\Users\...\AppData\Local\Programs\MiKTeX 2.9 path for caption.sty.

Stefan
Attachments
PICTURE4.PNG
PICTURE4.PNG (208.89 KiB) Viewed 923 times

User avatar
Stefan Kottwitz
Site Admin
Posts: 9501
Joined: Mon Mar 10, 2008 9:44 pm

Postby Stefan Kottwitz » Thu Sep 05, 2019 2:34 am

If you post the new .log file as attachment, we could see the errors in it.

Stefab
Site admin

User avatar
Ijon Tichy
Posts: 132
Joined: Mon Dec 24, 2018 10:12 am

Postby Ijon Tichy » Thu Sep 05, 2019 7:41 am

Maybe the errors come from an old *.aux, *.lof or *.lot file made by the outdated and removed caption.sty. You can delete those auxiliary files and make some new LaTeX runs. If the errors persist, see Stefan's post.

BTW: Some other package files, i. e., enumitem.sty, seem to be in the document folder, too. This could also cause problems. Generally it is better to use the »MiKTeX console« to install (and update) packages. But indeed sometimes it could be nesseccary to use local (outdated) copies to process an old document. But in this case it is always risky to combine local copies with distribution files.

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. pdfTeX warning (ext4): destination with the same identifier (name{page.1}) has
  2. been already used, duplicate ignored

It seems, you've two pages with the logical number 1. This often happens, if users use a \pagenumbering{arabic} (without having a \pagenumbering{roman} or similar before) or \setcounter{page}{1} after the title (which is typographically wrong).

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. pdfTeX warning (ext4): destination with the same identifier (name{page.2}) has
  2. been already used, duplicate ignored

Same for page 2.

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. l.130 $$
  2. \phi=U_0x+\varepsilon\varphi_{1}+\varepsilon^{2}\varphi_{2}+\varepsi...

It seems also, you've used $$…$$ to make displayed math. You should not use $$…$$ in LaTeX. This is low-level TeX and breaks several LaTeX features (like correct spacing an alignment of the equation). Better use \[…\].

To say more, I would need a Infominimal working example that can be used to reproduce the messages in the log-file.

User avatar
sommerfee
Posts: 498
Joined: Mon Apr 09, 2007 4:20 pm

Postby sommerfee » Thu Sep 05, 2019 10:24 am

There is an old version of subcaption.sty in the document directory, too, which is incompatible to the caption package version you use. Please simply delete it as well, so the version included in MikTeX will be used instead.

mimi04
Posts: 12
Joined: Tue Sep 03, 2019 1:17 pm

Postby mimi04 » Thu Sep 05, 2019 11:58 am

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. pdfTeX warning (ext4): destination with the same identifier (name{page.1}) has
  2. been already used, duplicate ignored

It seems, you've two pages with the logical number 1. This often happens, if users use a \pagenumbering{arabic} (without having a \pagenumbering{roman} or similar before) or \setcounter{page}{1} after the title (which is typographically wrong).

Here I want to show the pages with: i , ii, ...beginning with Acknowledgement, table of content ....But the numbering page 1,2,3....beginning with introduction.

Please how can I do this?

User avatar
Ijon Tichy
Posts: 132
Joined: Mon Dec 24, 2018 10:12 am

Postby Ijon Tichy » Thu Sep 05, 2019 12:12 pm

This would be a new question, that should be ask as a new thread. And as I already told you: I need a Infominimal working example, that can be used to reproduce the problem. Without every suggestions is theoretical speculation.

However, try any book in you bookshelf. The pages are counted from the first right page behind the cover. The title pages do not show the page number but are counted invisibly. So you should switch to small Roman numbers before the title page. An if you have a cover pages, you should use a different numbering scheme for them. And with class book, you should use \frontmatter to start the front matter and \mainmatter to switch to the main matter. The front matter uses small Roman pagenumbers automatically, the main matter uses Arabic pagenumbers automatically.


Return to “General”

Who is online

Users browsing this forum: No registered users and 9 guests