如何使用javascript获取gridview中选中的单选按钮列表的总和. [英] how to get the sum of checked radio button list in gridview using javascript.

查看:69
本文介绍了如何使用javascript获取gridview中选中的单选按钮列表的总和.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hii

我有一个带有1列的网格视图,一个单选按钮列表位于该网格视图中.
我的要求是,我必须使用Java脚本获取网格视图中选中的单选按钮的值之和.
为了更清晰:网格视图中有三行,我最后检查了每一行中的任何一个单选按钮,最后我必须得到一个警报,以使用javascript ...显示选中的单选按钮的总和.
在此先感谢...........

Hii

i have a grid view with 1 column , a radio button list is placed in the grid view .
My requrment is , i must get the sum of the values of the checked radio buttons in the grid view by using java script.
for more clarity: there are three rows in the grid view , i check any one radio button in each row finally i must get an alert to display the sum of the checked radio buttons by using javascript....

thanks in advance...........

推荐答案

var total;


("input [id
("input[id


=''someid'']).each(function() { 总计+ = int.Parse(
=''someid'']").each(function() { total += int.Parse(


这篇关于如何使用javascript获取gridview中选中的单选按钮列表的总和.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆