Dojo Datagrid 抛出“单元格未定义”
cell = document.createElement("td");
cell.setAttribute("colspan", "1");
cell.setAttribute("valign", "top");
var grid = new dojox.grid.DataGrid({
id: "gridID",
store: new dojo.data.ItemFileWriteStore({data: {items: []}}),
elasticView: "2",
selectionMode: "single",
autoWidth: "true",
rowCount: "4",
layout: [{field: "name", editable: "false", width:"160px", name:"fieldname"}],
query: "{itemID:'*'}"
}).placeAt(cell);
grid.startup();
row.appendChild(cell);
启动后会抛出错误“单元格未定义”(943 超出范围 516)
cell = document.createElement("td");
cell.setAttribute("colspan", "1");
cell.setAttribute("valign", "top");
var grid = new dojox.grid.DataGrid({
id: "gridID",
store: new dojo.data.ItemFileWriteStore({data: {items: []}}),
elasticView: "2",
selectionMode: "single",
autoWidth: "true",
rowCount: "4",
layout: [{field: "name", editable: "false", width:"160px", name:"fieldname"}],
query: "{itemID:'*'}"
}).placeAt(cell);
grid.startup();
row.appendChild(cell);
After it starts up it throws the error "cell is undefined" (943 out of range 516)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
总是仔细检查白痴的错误。 “布局”应该是“结构”。应该会弹出比单元格未定义更好的消息。
Always double check the idiot mistakes. "Layout" should be "structure". There should be a better message popping up than cell is undefined.