Hi all,<br><br>I'm trying to define a command that changes it's behavior depending on whether the class file defines chapters or not. Is there an easy way to test for whether a macro is defined? I'd like to do something like this:<br>
<br>\newcommand{\todo}[2][]<br>\stepcounter{TodoCounter}<br>\ifx <\chapter is defined><br>\addcontentsline{tdo}{todo}{\textbf{\arabic{chapter}.\arabic{section}-\arabic{TodoCounter}:} #2}<br>\else<br>\addcontentsline{tdo}{todo}{\textbf{\arabic{section}-\arabic{TodoCounter}:} #2}<br>
\fi<br>}<br><br>Can anyone let me know what the correct way to test for this is? Thanks!<br><br>-- Chris<br><br><br><br>