EasyUI Forum
October 03, 2025, 08:43:11 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Datagrid getValue of specific cell [solved]  (Read 20019 times)
can2pic
Newbie
*
Posts: 6


View Profile
« on: May 18, 2013, 08:51:58 AM »

I've been trying to work out how to repeatedly get the value a specific datagrid cell for about 10 hours now,Please can someone help to correct my code? I haven't quite got to grips with this yet Cry , for example my column name is Part_Number and the the index is row 5 and I need to get the current value, I would have previously used document.getElementById

Code:
var v = $('#dg_spn').datagrid('getValue',{index: 5,row:{Part_Number:}});
alert(v);

Thanks
« Last Edit: May 19, 2013, 01:45:22 AM by can2pic » Logged
stworthy
Administrator
Hero Member
*****
Posts: 3581


View Profile Email
« Reply #1 on: May 18, 2013, 08:26:03 PM »

Try this:
Code:
var v=$('#dg_spn').datagrid('getRows')[5].Part_Number;
Logged
can2pic
Newbie
*
Posts: 6


View Profile
« Reply #2 on: May 19, 2013, 01:44:51 AM »

Thank you stworthy, that works fine!
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!