Accessing kendo grid cell values

user990423

I have an web application that uses Kendo Grid. How would I obtain the values of "Ticket No" of the selected check-boxes?

enter image description here

My code is:

var grid = $("#poGrid").data("kendoGrid");
grid.items().filter(":has(:checked)").each(function () {
    var tr = $(this);
    console.log(grid.dataItem(tr));
    console.log("Length => " + grid.dataItem(tr.length.toString()));
});

console.log(" grid.items().length => " + grid.items().length);
console.log(" grid.dataItem.ticketNumber => " + grid.dataItem.ticketNumber);    

Output:
enter image description here

Daniel Pflüger

You can do something like this:

grid.items().filter(":has(:checked)").each(function () {
  var tr = $(this);

  // Current data item
  var dataItem = grid.dataItem(tr);
  console.log(dataItem);

  // Access the ticketNumber
  var ticketNumber = dataitem.ticketNumber;
  console.log("ticketNumber=> " + ticketNumber );
});

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Kendo Grid Filterable cell

From Dev

Kendo Grid Filterable cell

From Dev

Clickable Cell in Kendo Grid

From Dev

How to show ellipsis for long cell values in kendo ui grid?

From Dev

How to conditionally format Kendo UI grid cell (depending on values) razor

From Dev

Kendo Grid Not Saving Values After Moving to the next cell

From Dev

Sum of Values in Kendo Grid

From Dev

displaying values in kendo grid

From Dev

Kendo grid editable multiselect grid cell

From Dev

Accessing clientside data in a Kendo Grid Detail Template

From Dev

How do I display Kendo Grid inside Kendo Grid cell?

From Dev

Formatting of values in dynamic Kendo grid

From Dev

kendo grid select cell data on focus

From Dev

Show dropdown in cell of kendo grid in template

From Dev

How to show € symbol in a kendo grid cell

From Dev

how to get cell click event in kendo grid

From Dev

Make cell readonly in Kendo Grid if condition is met

From Dev

Kendo Grid: Removing dirty cell indicators

From Dev

Kendo grid cell refocusing after refresh

From Dev

Styling cell in Kendo grid via ClientTemplate

From Dev

Remote update cell content in kendo grid

From Dev

how to focus next cell in kendo grid by enter

From Dev

Kendo UI grid filter cell that contains an array

From Dev

Kendo grid change style cell data

From Dev

how to focus next cell in kendo grid by enter

From Dev

Kendo UI grid conditionally editable cell

From Dev

How to mark Kendo Grid's cell as edited?

From Dev

Kendo UI grid filter cell that contains an array

From Dev

make a kendo cell readonly based on dropdownselection in the grid