I try to show a dynamic result set in a dataview.
In a store 'Headers' I have loaded all the columns that have to be loaded in a new (json) store.
In the onStoreLoad event of the store 'Headers' I have code shown below.

The problem is that the created dataview does not show any fields. When I look in Chrome (developer tools) I see that the created store does have data.
When I force the webservice to give no results then I get the text 'No data', that is the correct value from the property emptyText. So, the dataview is visible.
It seems that the binding between store and dataview is not correct. The fieldnames are correct.

What is wrong in this code?

var tpl = '';
var fields = new Ext.data.Field();
var max = records.length;
for (var i = 0; i < max; i++)
    var field = new Ext.data.Field({
        name: records[i].get('cname')
    tpl = tpl + '{' + records[i].get('cname') + '} ';
    fields[i] = field ;
var store = new Ext.data.Store({
    proxy: {
        type: 'jsonp',
        url : 'http://tspalm/toolkit/callback.php?level=9&commandid=' + MyApp.sqlCommandId + '&viewid=' + MyApp.sqlView,
        reader: {
            type: 'json'
    fields: fields

var dv = new Ext.DataView({
        store: store,
        height: 445,
        emptyText: 'No data',
        itemTpl: tpl,
        tpl: new Ext.XTemplate(
        '<tpl for=".">',
            '<div class="item">'+ tpl + '</div>',
var panel = new Ext.Panel({
    alias: 'widgets.resultsview',
    fullscreen: true,

    items: [
            xtype: 'button',
            text: 'Refresh',
            handler: function()

var  p = Ext.getCmp('mynavigationview');