Search code examples
latex

In LaTeX not able to add space (i.e. use \vspace{length}) in multicolumn (i.e. in \begin{multicols} environment)


I am trying to add vertical space in first column but after writing \vspace{10cm}, still not getting the required result. Image of required result can be found here. If there is some problem in code (Code is attached), then please correct. Otherwise you can also suggest other method.

\documentclass{article}
    \usepackage{multicol}
    \usepackage{tikz}
    \begin{document}
        \begin{multicols}{2}
            \vspace{10cm}
            \begin{flushleft}
                Date:
                \\ Place
            \end{flushleft}
            
            \columnbreak
            Examiners   \\
            \begin{flushright}
                
                \par
                1.\begin{tikzpicture}
                    \draw [thick,densely dashed={dash pattern=on 3pt off 2pt}] (0,0) -- (7,0);
                \end{tikzpicture}
                \par
                2.\begin{tikzpicture}
                    \draw [thick,densely dashed={dash pattern=on 3pt off 2pt}] (0,0) -- (7,0);
                \end{tikzpicture}
            \end{flushright}
        \end{multicols}
    \end{document}

Solution

  • It will work if the \vspace is not the first thing in the column. You could add something invisible like \mbox{} before it.

    Off-topic:

    • using tikz for the doted lines feels a bit overkill, you could use \dotfill instead (this would also avoid the overfull box warnings)

    • you shouldn't abuse \\ for line breaks, this causes many underfull box warnings. Just leave an empty line instead to start a new paragraph

    \documentclass{article}
    \usepackage{multicol}
    
    \begin{document}
        \begin{multicols}{2}
            \mbox{}
            \vspace{10cm}
            \begin{flushleft}
                Date:
                
                Place
            \end{flushleft}
            
            \columnbreak
            
            Examiners   
            
            \begin{flushright}
                \par
                1.\dotfill
                \par
                2.\dotfill
            \end{flushright}
        \end{multicols}
    \end{document}