Hi,

i have an issue with an editable grid panel with a combo box.

Here is the code of a javascript Renderer fn:




<script type="text/javascript">


function CategoryRenderer(value) {


var r = CategoryIDStore.getById(value);


if (Ext.isEmpty(r)) {


return "";


}


return r.data.Category;


}


</script>
and this is the grid column:




<ext:Column ColumnID='CategoryID' DataIndex='CategoryID' Header='Category' width="160">


<Renderer Fn="CategoryRenderer"/>


<Editor>


<ext:ComboBox 


ID='CategoryIDGrid' 


Runat='Server' 


FieldLabel='CategoryID' 


StoreID='CategoryIDStore' 


DisplayField='Category' 


ValueField='CategoryID' 


TypeAhead='true' 


ForceSelection='true' 


TriggerAction='All' 


/>


</Editor>


</ext:Column>
and finally CategoryIDStore:




<ext:Store ID='CategoryIDStore' runat='server'


DataSourceID='CategoryIDDataSource' 


OnRefreshData='CategoryIDStore_RefreshData'


AutoLoad='True'>


<Proxy><ext:DataSourceProxy /></Proxy>


<Reader>


<ext:JsonReader ReaderID='CategoryID'>


<Fields>


<ext:RecordField Name='CategoryID' />


<ext:RecordField Name='Category' />


</Fields>


</ext:JsonReader>


</Reader>


<Listeners>


<LoadException Handler="Ext.Msg.alert('ProductsCategories - Load failed', e.message || response.statusText);" />


</Listeners>


</ext:Store>
When i load page at first time grid column is empty but if i click on gridpanel toolbar refresh button or go to another page or something than trigger a grid update, then column is populated.

seems like store is not loaded at first page render time.

iŽll try in page_load sub add a line "CategoryIDStore.DataBind()" but no worked...

do you know how to force loading of store...

Thanks for your time.

Regards,

Rinaldo J. Sassaroli