Thank you Thorsten for your speedy reply.
Indeed, you provide me with a way to solve my problem! All it takes is
\begin{center}\begin{tabular}{*{\value{nbcol}}{c}}
which is much simpler than what I was trying to do... :oops:
I am however still curious about what was causing the bug, as that way ...
Search found 2 matches
- Sat Jul 02, 2011 8:29 pm
- Forum: Graphics, Figures & Tables
- Topic: Table with Number of Columns as Parameter
- Replies: 2
- Views: 4593
- Sat Jul 02, 2011 6:49 am
- Forum: Graphics, Figures & Tables
- Topic: Table with Number of Columns as Parameter
- Replies: 2
- Views: 4593
Table with Number of Columns as Parameter
I am trying to create an environment for building a table. The number of columns wanted would be passed as a parameter. This is my MWE:
\documentclass{amsart}
\usepackage{ifthen}
\newcounter{nbcol}
\newcounter{nbcolt}
\newcommand{\tmpcmd}{}
\newenvironment{tabledl}[1]{
\setcounter{nbcol}{#1 ...
\documentclass{amsart}
\usepackage{ifthen}
\newcounter{nbcol}
\newcounter{nbcolt}
\newcommand{\tmpcmd}{}
\newenvironment{tabledl}[1]{
\setcounter{nbcol}{#1 ...