6

There are addpoints and noaddpoints commands for the exam class in order to show or hide points of questions. However, I can't hide points by adding noaddpoints option or command.

If I delete the point near the question ([5]), point disappears but I want to keep the point as is and just don't print it. Is it possible?

\documentclass[noaddpoints]{exam}
\noaddpoints
\begin{document}
\begin{questions}
    \question[5] Test 2
    \question Test 1
\end{questions}
\end{document}
0

3 Answers 3

6

No need noaddpoints as an option. Add to preamble

\nopointsinmargin
\pointformat{}

\documentclass[]{exam}
\nopointsinmargin
\pointformat{}
\begin{document}
\begin{questions}
    \question[5] Test 2
    \question Test 1
\end{questions}
\end{document}
0
5

The accepted answer indeed hides the points, but it leaves a space at the start of the question where the points usually appear. This can be avoided by using \pointsinmargin together with \pointformat{} instead.

\documentclass{exam}
\usepackage{lipsum}

\begin{document}
\pointformat{}
\begin{questions}
\nopointsinmargin
\question[5] \lipsum[66]

\pointsinmargin
\question[5] \lipsum[75]
\end{questions}
\end{document}

enter image description here

4

I use a version of the answer by @ferahfeza to hide points for parts of exams or handouts where I have some custom question formats. I created two macros to hide and show points as necessary.

\documentclass{exam}

\newcommand{\hidepoints}{%
    \pointsinmargin\pointformat{}
}

\newcommand{\showpoints}{%
    \nopointsinmargin\pointformat{(\thepoints)}
} %You would set the \pointformat to whatever format you use.

\begin{document}

\begin{questions}

\question[1]
This question will show points because it is the exam class default.

\hidepoints

\question[1]
This question will not show the points because they are now hidden.

\showpoints

\question[1]
Once again, the points are visible.

\end{questions}

\end{document}

Hidden and visible points

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .