Qlik Community

Qlik Sense Integration, Extensions, & APIs

Discussion board where members can learn more about Integration, Extensions and API’s for Qlik Sense.

bobobobob
New Contributor

How can I get value from promise without specifying callback function in the creatList method?

Hello, how can I get value from promise without specifying the callback function in the creatList method?

When I do like this I don't receive value in the callback...

var list = app.createList({

        "qFrequencyMode": "V",

        "qDef": {

                "qFieldDefs": [

                        "GroupName"

                ]

        },

        "qExpressions": [],

        "qInitialDataFetch": [

                {

                        "qHeight": 2000,

                        "qWidth": 1

                }

        ],

        "qLibraryId": null

    });


list.then(function(reply, app){

   //reply.qListObject is undefined

   //app is undefined

})

1 Reply
erik_wetterberg
Valued Contributor III

Re: How can I get value from promise without specifying callback function in the creatList method?

Hi,

The promise resolves when the object is available on the client. After that data is fetched through getLayout. To get the data you can use the Validated event.

Erik Wetterberg

Erik Wetterberg
https://extendingqlik.upper88.com/
Community Browser