Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
mattias-thalen
Contributor II
Contributor II

Add conditional show in app.visualization.create

Hi,

I'm trying to populate the table property Add-ons > Data Handling > Calculation Condition & Message when creating a table using app.visualization.create:

 

app.visualization.create(
    "table",
    columns,
    {
        multiline: { wrapTextInCells: true },
        components: [{
            key: "theme",
            content: { hoverEffect: true },
            scrollbar: { size: "medium" }
        }]
    })

 

I've successfully done it to the fields using this:

 

qCalcCondition: { qCond: '=1' }

 

But I'm unsure how to implement it for the table object.

Labels (3)
1 Solution

Accepted Solutions
mattias-thalen
Contributor II
Contributor II
Author

Found the solution by using console.log() and checking the properties of the object created from app.visualization.create()

app.visualization.create(
    "table",
    columns,
    {
        multiline: { wrapTextInCells: true },
        components: [{
            key: "theme",
            content: { hoverEffect: true },
            scrollbar: { size: "medium" }
        }],
        qHyperCubeDef: {
            qCalcCondition: {
                qCond: "=1",
                qMsg: "Condition not met"
            }
        }
    })

View solution in original post

1 Reply
mattias-thalen
Contributor II
Contributor II
Author

Found the solution by using console.log() and checking the properties of the object created from app.visualization.create()

app.visualization.create(
    "table",
    columns,
    {
        multiline: { wrapTextInCells: true },
        components: [{
            key: "theme",
            content: { hoverEffect: true },
            scrollbar: { size: "medium" }
        }],
        qHyperCubeDef: {
            qCalcCondition: {
                qCond: "=1",
                qMsg: "Condition not met"
            }
        }
    })