Product Bundles
DevCraft
All Telerik .NET and Kendo UI JavaScript components and AI Tools in one package.
Kendo UI
Bundle of AI Tools plus four JavaScript UI libraries built natively for jQuery, Angular, React and Vue.
Telerik
Build great .NET business apps
Net Web
Cross-Platform
Desktop
Reporting and Documents
Testing & Mocking
Debugging
Build JavaScript UI
Javascript
AI for Developers & IT
Ensure AI program success
AI Coding
Additional Tools
Enhance the developer and designer experience
UI/UX Tools
Free Tools
CMS
Support and Learning
Productivity and Design Tools
Hello! I create radgrid data dynamically, and i don't even know how many columns it contains and column names are unknown.
The values are simple integers. The task is to calculate the summ of cells values of specific row. How can i iterate through columns
client-side javascript ?
You can loop through the column collection of the GridTableView to get names and how many. From there I would think you need to find the dataItem and then sum up the value in each element.
http://docs.telerik.com/devtools/aspnet-ajax/controls/grid/client-side-programming/gridtableview-object/gridtableview-class-members
Not simple with a dynamic grid but doable.
Thank You, Craig. I've done it. Just Like This
01.
var
masterTable = $find(
"<%=RadGrid1.ClientID%>"
).get_masterTableView();
02.
count = masterTable.get_columns().length;
03.
row = args.get_row();
04.
cells = row.cells;
05.
sum = 0;
06.
07.
for
(
j = 0; j < count; j++) {
08.
09.
s = parseInt(cells[j].innerText);
10.
sum = sum + s;
11.
}
12.
alert(sum);