May 16, 2012, 4:28 PM
[CLOSED] Store Problem
I have a Store:
@(Html.X.Store().ID("EmployeeData") _
.DataSource(ViewData("Employees")) _
.Model(Sub(mdl)
mdl.Add(Html.X.Model.Fields(Sub(flds)
flds.Add("Text")
flds.Add("Value")
End Sub))
End Sub))
And I have a grid where I want the store to be used as the source in a column editor, so I am trying to set the editor's store to the ID of my predefined one.cols.Add(Html.X.Column().DataIndex("DrafterEmployeeID").Text("Drafter1").Editor(Sub(edt)
Dim cbo As New Ext.Net.ComboBox
With cbo
.ID = "DrafterEmployeeID"
.StoreID = "EmployeeData"
.MultiSelect = False
.AutoDataBind = True
.TypeAhead = True
.DisplayField = "Text"
.ValueField = "Value"
End With
edt.Add(cbo)
End Sub))
When I run the page, I keep getting an error that the store (with ID "EmployeeData") cannot be found. I do have the store definied before the grid and when I view the source for the page, I see this:window.App.EmployeeData=Ext.create("Ext.data.Store",{model:Ext.define(Ext.id(), {extend: "Ext.data.Model", fields:[{name:"Text"},{name:"Value"}] }),storeId:"EmployeeData",autoLoad:true,proxy:{data:...
What are some possibilities as to why my grid having trouble finding the store?
Last edited by Daniil; May 21, 2012 at 1:25 PM.
Reason: [CLOSED]