Multiple Markdown tables in a calc field



  • Rainer Grabowski

    Hi RIch,

    that should be simple: 

    "text text text \n\n" +

    table1 \n\n"+

    "text text text \n\n" +

    table2 \n\n" +

    table 3


    Or create a var for each element: 
    var t1 = "text1 text1 text1";
    var table1 = "your table code";
    and so on for the other elements

    t1 + "\n\n" + table1 + "\n\n" + ...


    Comment actions Permalink
  • Rich Siegmund

    Rainer - I agree that makes sense but I've found it not to work as expected.

    I would imagine that \n\n is treated as a termination character and that the following table would be completely independent, however I found that columns interacted in odd ways.

    I'll try this out again, kind of busy at the moment, maybe I was doing something odd, but I spent some time experimenting and could not get two inpdendent tables with different numbers of columns to properly format such that it appears there are two tables both with bolded headings and separator lines under the headings.

    I've never found a way to create an arbitrary number of blank rows either in a calc field....  Know any way to accomplish that?  They seem to keep being stripped out.

    Comment actions Permalink
  • Rainer Grabowski

    Hi Rich,

    this example should give you an idea how it works: 2 tables in one calc field with an arbitrary number of blank rows betweeen them (6 in this case):

    "Table 1: \n\n" +
    "c1 | c2 | c3 \n" +
    "--- | --- | --- \n" +
    " A | B | C" +

    "\n   \n   \n   \n   \n   \n   \n"+

    "Table 2: \n\n" +
    "d1 | d2 | d3 | d4 \n" +
    "--- | --- | --- | --- \n" +
    " D | E | F | G"


    Hope that helps,


    Comment actions Permalink
  • Ben Kern

    inserting "\n \n\n" between two tables (or table variables) works consistently for me

    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk