how to give row information different for each row while binding from ajax dataSource

Posted by Manorama under jQuery on 4/25/2013 | Points: 10 | Views : 783 | Status : [Member] | Replies : 1
hi to all......

here my Requirement is binding Data table 1.9 Dynamically for this i am calling Data thru ajax source with webMethod.and I have 3 rows for columns;
Now I want different data for 3 rows like row1 containing ex1,row2 contains ex2,row3 means ex3;currently i am getting ex1 for all 3 rows;first of all i am unable to get 3 different values from ajax;and i don't know how to bind this to rows of Data table 1.9 using Html;
public static string[] GetNewColumnData(string columnname)
string[] colData = new string[3];
DataClasses1DataContext db = new DataClasses1DataContext();
Table<RowData_tbl> row = db.GetTable<RowData_tbl>();
Table<TreeviewChildNodes_tbl> child = db.GetTable<TreeviewChildNodes_tbl>();
//Query for getting Id of ColumnName
var colId = from cid in child
where cid.ChildName.Equals(columnname)
select new { id = cid.ChildId };
Int64 col=0;
foreach(var item in colId)
col= Int64.Parse(;
//Query for Getting Row Information According to Column Name
var rowData = from c in row
where c.ChildId.Equals(col)
select new { rowName=c.RowTitle }; .................this rowData holds 3 different values from DB

string rowDetails = string.Empty;
foreach (var r in rowData)
rowDetails = r.rowName.ToString();
foreach (var r in rowData)
for (int i = 0; i < rowData.Count(); i++)
colData[i] = r.rowName.ToString(); .....//here I am getting Same Information How to extract the information of rowdata



catch (Exception ex)

return colData;
How to extract the information of rowdata Please guide me



Posted by: Jitendrasoft09 on: 4/30/2013 [Member] [MVP] Starter | Points: 25

You can use jquery to extract the rowdata, please look into below link that would be helpful for you.

Jitendra Kumar
If my post helps you, plz mark as an answer.

Manorama, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response