I have a custom command for the package todonotes


which is supposed to be used like:

\custom[inline]{author1,some comments}

Instead, it raises the error:

E: main.tex:124 Package xkeyval Error: `some comments' undefined in families `todonotes'

What is going on? I've defined 3 arguments with argument 1 as optional!

  • You are only specifying two parameters, it should probably read \custom[inline]{author1}{some comments}. In your case, you are using \todo[inline,author=author1,some comments] where some comments is an invalid key for the todonotes package. – epR8GaYuh Feb 20 '18 at 14:23
  • 1
    Rather than xargs, I'd use xparse and \NewDocumentCommand{\custom}{O{}mm}{\todo[#1,author=#2]{#3}} with a call such as \custom[inline]{author1}{whatever}. More robust. – egreg Feb 20 '18 at 14:51
  • Any news here ? – Bobyandbob Oct 5 '18 at 9:22

Your Answer

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

Browse other questions tagged or ask your own question.