I'm trying to write a package for personal use that takes custom arguments as follows:

\ProvidesClass{ZTPS}[2014/15/10 v1.0 Zach Taylor Problem Set]

\RequirePackage[margin=1in]{geometry} % Put BEFORE fancyheader!



\DeclareStringOption [Zachary Taylor]{name}
\DeclareStringOption [\today]{date}
\DeclareStringOption [MTH 265]{course}
\DeclareStringOption [Untitled]{title}



If I invoke it as follows, everything works fine and the header/footer include the default option values (My name, "MTH 265", and the date.):






However, if I try:






I get

"Unknown Option: 'name=test' for package 'zpts'".

If I just put [name] I get the same error

"Unknown Option: 'name' for package 'zpts'".

I'm probably missing something simple but I've searched extensively and can't find it.

  • 2
    I don't see a line to process options in your short demo file: we'll need to see that. Also (not linked to the issue): you've got \ProvidesClass but the code seems to be a package, which should be corrected. – Joseph Wright Oct 15 '14 at 7:40
  • That turned out to be my problem, actually-- thanks for pointing it out. – Dumb Political Scientist Oct 19 '14 at 10:08

Options are processed (by kvoptions) only when you give the command


which is missing in your input. As such, whilst you've declared lots of options none of them are ever 'activated'.


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.