The reply contains a qListObject.qDataPages[0].qMatrix property and I can loop through this to get the fields ('Germany', 'France', 'Sweden' etc).

Elsewhere in code, I make the same call for the same field (country), but rather than getting back the fields, I don't get the qListObject property, and the qFieldList property contains the 2 fields that are available in the app:

This doesn't seem to make any sense - make the same call, and you should get the same data back, shouldn't you? The only difference is that the second call uses an 'app' reference returned from an openApp(...) call, but I don't see why this would cause the issue.

Re: API CreateList strangeness (unexplained behaviour)

Thanks for your reply. I definitely get those two different responses for the same call.

I am using the 'mashups' API because I need to call 'openApp' and work with 'app level' objects that are 'outside' of the scope of the extension. I can find no mention in the docs that getList and createList should be avoided if possible in an extensions context - is this for performance reasons?

Also, I'm not using a 'paint' function; I'm using Angular with a template and some $scope level functions to call code.

Re: API CreateList strangeness (unexplained behaviour)

Hi Shane,

If you are working with another app you will need to use the Mashup API calls, initialProperties will only work with the current app.

The problem with using the createCube, createList, getList etc calls from within an extension is that they will create a session object every time they are called. The paint() method is called on all changes that affects the visualization, so that means a lot of calls, more than most people think. The same goes for the angular approach: angular might call your method more times than you think, so you will end up with many session objects.

Also the mashup API sets up a subscription, so the callback you provide might be called several times, which maybe is not what you expected.

Re: API CreateList strangeness (unexplained behaviour)

Hi Erik,

thanks for the info about initialProperties - the other issue is that the calls I'll be making are based on the current selections in the current app (I then get field information about the other app).

Are there any guidelines for calling those API methods? Calling things needlessly is never a good idea, but what techniques can Sense developers employ to improve performance and reduce session creation?

Re: API CreateList strangeness (unexplained behaviour)

Well you need to keep track of your open apps and created objects. In chrome developer tools you can easily see your created web sockets (every open app has its own web socket). You can also set breakpoints in your callback functions and verify that they are called the way you expect.