View Full Version : unable to populate the values from the extjs to the controller

21 Aug 2009, 7:50 AM
Hi all,
I am new to ExtJs. I am having a grid and onclick of any particular row i am getting the row information to the js file. Now my main problm is I am unable to get that particular selected value to the controller. My code is as follows..

js file..

var rowContent = schoolInfoGrid.getStore().getAt(rowIndex); // schoolInfoGrid is my Ext.grid value

Ext.log("ProgramId selected is :"+rowContent.get('programId'));

var store = new Ext.data.JsonStore({
root: 'schoolInfoGrid',
url: '/queryController/getProgramResults.vm',
method: 'POST',
programId: 'programId'

store.load({callback:function (){

The control is going to the controller but I am not getting the value of 'programId' in the controller. Kindly let me know if any mistatke in my js file and how to get that data in the controller.. I tried using request.getParameter("") but its not working..
Any small help will be most helpful.. Thanks in advance..

21 Aug 2009, 8:20 AM
That's because you're not sending it! add it to the params object of the store.load call.

That said, there is a *help* forum :)

21 Aug 2009, 8:56 AM
Hi garcia,
Thanks for ur quick response.. But as I told I am completly ne to extjs. Can u show me a sample code to add the Objects to param..

21 Aug 2009, 8:58 AM
programId : rowContent.get('programId')

21 Aug 2009, 8:58 AM
and please use cod tags in the future

21 Aug 2009, 9:32 AM
Thanku garica. You sugested me to use cod tags in future. Can u just tel me what the cod tags are and what are they for..
Thanku soo much garcia for ur reply and your valuable suggestion ..