# how to add conditions inside itemize list? [closed]

List mentioned below is having three items. There are four variables : 1] varone 2] vartwo 3] varthree and 4] sub ; which are coming from external CSV file. Item 2 with "Value B" will be displayed if value of variable sub is more than 4. But somehow this code does not work : can you please suggest me how to add conditions inside itemize list?

\begin{itemize}
\ifboolexpr{
test {\ifdimgreater{\varone pt}{69.99pt}} or
test {\ifdimequal{\varone pt}{69.99pt}}}
{\item \textbf{Value A: } Text for A.}{}
\ifnum\sub > 4
\ifboolexpr{
test {\ifdimgreater{\vartwo pt}{69.99pt}} or
test {\ifdimequal{\vartwo pt}{69.99pt}}}
{\item \textbf{Value B: } Text for B.}{}
\fi
\ifboolexpr{
test {\ifdimgreater{\varthree pt}{69.99pt}} or
test {\ifdimequal{\varthree pt}{69.99pt}}}
{\item \textbf{Value C: } Text for C.}{}
\end{itemize}


Note: I'm using article document class with xelatex.

## closed as unclear what you're asking by egreg, Johannes_B, Kurt, user36296, Mike RenfroJan 8 '17 at 15:15

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

• Could you please make the example into a complete compilable document? "Somehow doesn't work” is too generic. – egreg Dec 28 '13 at 16:48
• Perhaps this does not fit your usage, but: why not use e.g. python to generate a LaTeX file from the CSV file? – yyzz Dec 28 '13 at 18:44
• I don't see any problems in your code. It distilled a little MWE and it works flawlessly. – Henri Menke Dec 28 '13 at 19:29