2

This question already has an answer here:

I have this code :

\documentclass[french]{article}
\usepackage{pgfgantt}
\usepackage{babel}

\begin{document}

\begin{figure}[htbp]
\begin{ganttchart}[y unit title=0.4cm,
y unit chart=0.5cm,
vgrid,hgrid, 
title label anchor/.style={below=-1.6ex},
title left shift=.05,
title right shift=-.05,
title height=1,
bar/.style={fill=blue!50},
incomplete/.style={fill=white},
progress label text={},
bar height=0.7,
group right shift=0,
group top shift=.6,
group height=.3]{1}{21}
\gantttitle{2011}{21} \\
\gantttitlelist{1,...,21}{1} \\
\ganttbar{TA1}{1}{3} \\
\ganttbar{TA2}{1}{2} \\
\ganttbar{TA3}{4}{7} \\
\ganttbar{TA4}{8}{8} \\
\ganttbar{TA5}{8}{13} \\
\ganttbar{TA6}{14}{16} \\
\ganttbar{TA7}{14}{21} \\
\ganttbar{TA8}{17}{18} 

\ganttlink{elem1}{elem2} % <- Line that doesn't work

\end{ganttchart}
\end{figure}

\end{document}

It work fine except when i want to add liaison between task, with the line
\ganttlink{elem1}{elem2} that produce this error:

E: /Users/samuelriedo/Desktop/untitled.tex:21 Package tikz Error: + or - expected \ganttlink{elem1}{elem2}
E: /Users/samuelriedo/Desktop/untitled.tex:21 Package tikz Error: Giving up on this path. Did you forget a semicolon? \ganttlink{elem1}{elem2}

Does anyone have an idea why it doesn't work to draw arrows between nodes ?

marked as duplicate by Joseph Wright Sep 20 '16 at 12:01

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • I tried using \usepackage[frenchb]{translator} as in the other topic, but it's unfortunately not working. – Nakrule Sep 19 '16 at 12:26
  • 2
    @Andrew It is a duplicate of sorts, but not of that question. Nakrule: Add \usetikzlibrary{babel} after \usepackage{pgfgantt}. – Torbjørn T. Sep 19 '16 at 12:50
  • Better duplicate: Problem with babel and tikz using \draw/ (It's for spanish, but I think it's the same underlying problem, and the same fix, adding the babel library, helps here as well.) – Torbjørn T. Sep 19 '16 at 13:21

Browse other questions tagged or ask your own question.