This is a migrated thread and some comments may be shown as answers.

[Solved] Inside templatecolumn of radGrid, I have a radio Button. I want to check its value on client side ?..

2 Answers 198 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Abhinav Katiyaar
Top achievements
Rank 1
Abhinav Katiyaar asked on 08 Dec 2009, 10:23 AM
Inside templatecolumn of radGrid, I have a radio Button. I want to check its value on client side. I had written following code

 var grid = $find("<%=radGridQuotes.ClientID%>");
    var MasterTable = grid.get_masterTableView();
    var Rows = MasterTable.get_dataItems();  
    for (var i = 0; i < Rows.length; i++)
    {
        var row = Rows[i];

//After this i dont know how to find the radio button control. i tried    var radioButton = row.findControl("radioButtonApprove");  but this is throwing error as propert cant be found. can anyone help me on this?....

}

2 Answers, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 08 Dec 2009, 11:21 AM
Hello Abhinav,

You can use the findElement method for the row to access the radiobutton control as shown below:
js:
var grid = $find("<%=RadGrid1.ClientID %>"); 
var MasterTable = grid.get_masterTableView(); 
var Rows = MasterTable.get_dataItems(); 
for (var i = 0; i < Rows.length; i++) 
  { 
     var row = Rows[i]; 
     var radiobutton = row.findElement("radioButtonApprove"); 
  } 

Thanks
Princy.
0
Abhinav Katiyaar
Top achievements
Rank 1
answered on 09 Dec 2009, 04:31 AM
Thanks Princy,

          My problem is solved. Thanks for the prompt response.

Abhinav

Tags
Grid
Asked by
Abhinav Katiyaar
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Abhinav Katiyaar
Top achievements
Rank 1
Share this question
or