Question

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)

Was it helpful?

Solution

Always double check the idiot mistakes. "Layout" should be "structure". There should be a better message popping up than cell is undefined.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top