i tried to build this table using latex, i don't know what's wrong. What i want


 \multicolumn{2}{| r |}{\cellcolor{gray!25} Begin of Table}\\
 A) Something & B) something j\\
  C) Something & D) something j\\



  • welcome to tex.se! do you really need longtable? is many page long? from table image is seems that tabular* or tabularx can be is sufficient.
    – Zarko
    Dec 15, 2017 at 8:22
  • Your code doesn't compile: You set up the longtable as having a single column, yet you then have a \multicolumn{2}{..}{...} directive. Please make the code compilable -- so that it actually generates the error you're looking to fix.
    – Mico
    Dec 15, 2017 at 8:37

1 Answer 1


it is not clear, which table you like to obtain. if the first one, and if the table on the end will longer than one page, than solution can be:

\usepackage{longtable, tabularx}

%-------------------------------- show page layout, only for test

    with \verb+longtable+:
\multicolumn{2}{| c |}{\cellcolor{gray!25} Begin of Table}\\
 A) Something   & B) something j    \\
 C) Something & D) something j\\

with \verb+tabularx+:
\multicolumn{4}{| l |}{What is capital of Canada?}  \\
Berlin   & C &  Ottawa  & A    \\
Rome    & D &  Canberra & B    \\


enter image description here


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.