1
當我運行此EXTJS代碼時,出現錯誤'this.proxy'爲空或不是對象。你能幫我解決這個問題嗎?錯誤:'this.proxy'爲空或不是EXTJS中的對象
var myData = [
['J', 'MD'],
['A', 'VA'],
['S', 'DC'],
['M', 'DE'],
['B', 'NJ'],
['N', 'CA'],
['S', 'RT'],
['S', 'CG']
];
var store = new Ext.data.ArrayStore({
totalProperty : 8,
autoLoad : {
params : {
start : 0,
limit : 4
}
},
fields : [ {
name : 'fullName'
}, {
name : 'state'
} ]
});
store.loadData(myData);
var grid = new Ext.grid.GridPanel({
store : store,
columns : [ {
id : 'fullName',
header : "FullName",
width : 160,
sortable : true,
dataIndex : 'fullName'
}, {
header : "State",
width : 75,
sortable : true,
dataIndex : 'state'
} ],
stripeRows : true,
autoExpandColumn : 'fullName',
height : 350,
width : 600,
title : 'Array Grid',
bbar : new Ext.PagingToolbar({
store : store,
pageSize : 4,
displayInfo : true
}),
viewConfig : {
forceFit : true
}
});
@分子利用內存代理與
load
ING:感謝ü非常much.But當我執行在Eclipse中的直接功能上面的代碼,它作爲「對象沒有按」顯示錯誤t支持這個屬性或方法'。 –錯誤詳細信息:第7行,在'ext-all.js'文件中的字符23481 –
@Jackie,如果使用'ext-all.js',將無法找到問題所在。嘗試用'ext-all-debug.js'版本替換它。然後找出錯誤發生的地方(用什麼組件的方法)並告訴我結果。 –