wangxuebin Posted July 11, 2014 Posted July 11, 2014 Hi: How I get the text value of the cell of Unidbgrid when I click the cell? I want to get the value of cell I clicked in ExtEvents(client side) not in server side events. thank you in advance!
Sherzod Posted July 11, 2014 Posted July 11, 2014 Hi wxb_km. Basically, your question should be solved as follows: 1. Need to use the function cellclick(sender, metaData, td, cellIndex, record, tr, rowIndex, e, eOpts) 2. Here cellIndex - is the column index and rowIndex - the index of the row. http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.grid.View-event-cellclick 3. And use it to get the value: sender.store.getAt(rowIndex).get(cellIndex) i.e.: function cellclick(sender, metaData, td, cellIndex, record, tr, rowIndex, e, eOpts) { alert(sender.store.getAt(rowIndex).get(cellIndex)); } But in my case (I use UniGUI 0.94.0.1023, under certain circumstances), I think some of the variables swapped! For me works if I do so: function cellclick(sender, metaData, td, cellIndex, record, tr, rowIndex, e, eOpts) { alert(sender.store.getAt(tr).get(td)); } Try... Best regards. 1
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now