Forum /
Ext JS Community Forums 4.x /
Ext: Q&A /
Unanswered: how to display jason data in textfield
Unanswered: how to display jason data in textfield
hi!
i am using following code to fetch data using JsonStore but unable to display it in textfield, although it is being displayed in drop down.
var prices = new Ext.data.JsonStore({
autoDestroy: true,
url: 'transport.php?controller=templates&action=getPrice&propid=' + recId,
root: 'prices',
id: 'propprice',
fields: ['propertyID','price']
});
and following for textfield in toolbar.
{
xtype: 'textfield',
name: 'textfield1',
id:'textfield1',
fieldLabel: 'Text field',
value: prices
}
it displays "[object Object]"in textfield, i have tried prices[0] and prices['price'] as well in this case nothing is displayed.
Can anyone please help me on this?
Sencha is used by over two million developers. Join the community, wherever you’d like that community to be
or Join Us