I compiled my tex file in Linux without any problems (text edior: Xemacs). I'm now running the file in TeXWorks with MikteX. I used the subfig package and the following worked perfectly:




I kept getting the 'undefined control sequence' error after trying to compile it in Win7. Having done some research, I installed the caption package (by running pdflatex caption.ins) and changed the \subfloat command above to \subcaption. Now instead of the error above, I'm getting two new:

! Package caption Error: For a successful cooperation we need at least version ``2004/02/13 v1.2' of package listings, but only version ``2002/04/01 1.0 (Carsten Heinz)' is available.

The second one is:

! LaTeX Error: Counter too large.

When trying to install the caption package through mpm, I keep getting the 'connection failure' error.

I'm kind of lost here and have no idea what to do. Any suggestions?

closed as too localized by yo', Torbjørn T., Joseph Wright Jan 5 '13 at 22:57

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 5
    Welcome to TeX.SE. It seems that your listings package is quite old. I would suggest you upgrade to TeXLive2012 unless there is a really good reason to use a very old distribution. – Peter Grill Nov 15 '12 at 6:44
  • Either install TeX Live 2012 or upgrade to MiKTeX 2.9: your MiKTeX distribution seems quite old. If you don't have disk space constraints, do a full install. – egreg Nov 15 '12 at 14:01

Browse other questions tagged or ask your own question.