This is my RadGrid which i have bind from json on client side javascript but i want to access this grid values on server side in my code behind file.
<
telerik:RadGrid
ID
=
"radGridView2"
runat
=
"server"
AllowSorting
=
"True"
<br> OnNeedDataSource="radGridView2_NeedDataSource"<
br
> Width="800px" GroupPanelPosition="Top" <
br
> ResolvedRenderMode="Classic" <
br
> Height="35em" Enabled="False"><
br
> <
ClientSettings
><
br
> <
Scrolling
AllowScroll
=
"True"
UseStaticHeaders
=
"True"
></
Scrolling
><
br
> <
Selecting
AllowRowSelect
=
"True"
/><
br
> <
ClientEvents
OnRowSelected
=
"RowSelected"
/><
br
> </
ClientSettings
><
br
> <
br
> <
SelectedItemStyle
BorderStyle
=
"Dashed"
<br> BorderWidth="1px"/><
br
> <
MasterTableView
AutoGenerateColumns
=
"False"
><
br
> <
Columns
><
br
> <
telerik:GridBoundColumn
DataField
=
"SNO"
UniqueName
=
"SNO"
HeaderText
=
"SN#"
><
br
> <
HeaderStyle
Width
=
"10px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"INITIAL"
UniqueName
=
"INITIAL"
HeaderText
=
"TYPE"
><
br
> <
HeaderStyle
Width
=
"10px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"TITLE"
UniqueName
=
"TITLE"
HeaderText
=
"ACCOUNT TITLE"
><
br
> <
HeaderStyle
Width
=
"80px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"DISC"
UniqueName
=
"DISC"
HeaderText
=
"DESCRIPTION"
Resizable
=
"False"
><
br
> <
HeaderStyle
Width
=
"160px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"JOB"
UniqueName
=
"JOB"
HeaderText
=
"COST CENTER"
><
br
> <
HeaderStyle
Width
=
"55px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"dRR"
UniqueName
=
"dRR"
HeaderText
=
"DEBIT"
DataFormatString
=
"{0:N}"
><
br
> <
HeaderStyle
Width
=
"35px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"cRR"
UniqueName
=
"cRR"
HeaderText
=
"CREDIT"
DataFormatString
=
"{0:N}"
><
br
> <
HeaderStyle
Width
=
"35px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"acno"
UniqueName
=
"acno"
HeaderText
=
"acno"
Visible
=
"false"
><
br
> <
HeaderStyle
Width
=
"35px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"job_id"
UniqueName
=
"job_id"
HeaderText
=
"job_id"
Visible
=
"false"
><
br
> <
HeaderStyle
Width
=
"35px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"U_INSERT"
UniqueName
=
"U_INSERT"
HeaderText
=
"U_INSERT"
Visible
=
"false"
><
br
> <
HeaderStyle
Width
=
"35px"
/><
br
> </
telerik:GridBoundColumn
><
br
> <
telerik:GridBoundColumn
DataField
=
"I_DATE"
UniqueName
=
"I_DATE"
HeaderText
=
"I_DATE"
Visible
=
"false"
><
br
> <
HeaderStyle
Width
=
"35px"
/><
br
> </
telerik:GridBoundColumn
><
br
> </
Columns
><
br
> </
MasterTableView
><
br
> <
ClientSettings
><
br
> <
ClientEvents
OnCommand
=
"function(){}"
/><
br
> </
ClientSettings
><
br
> <
ItemStyle
BorderStyle
=
"Ridge"
/><
br
> </
telerik:RadGrid
> <
br
>
This is how i am accessing my RadGrid
<
p
style
=
" background-color: #fff;"
><
font
color
=
"#000000"
face
=
"monospace"
> foreach (GridDataItem item in radGridView2.Items)<
br
> {<
br
> string idd1 = item["acno"].Text.Trim();<
br
> string type = item["INITIAL"].Text.Trim();<
br
> string jbid = item["job_id"].Text.Trim();<
br
> string disc = item["DISC"].Text.Trim();<
br
> string dRR1 = item["dRR"].Text.Trim().Replace(",", "");<
br
> string cRR1 = item["cRR"].Text.Trim().Replace(",", "");<
br
> string un1 = item["U_INSERT"].Text.Trim();</
font
></
p
><
p
style
=
" background-color: #fff;"
><
font
color
=
"#000000"
face
=
"monospace"
>}​</
font
></
p
>
{
string idd1 = item["acno"].Text.Trim();
string type = item["INITIAL"].Text.Trim();
string jbid = item["job_id"].Text.Trim();
string disc = item["DISC"].Text.Trim();
string dRR1 = item["dRR"].Text.Trim().Replace(",", "");
string cRR1 = item["cRR"].Text.Trim().Replace(",", "");
string un1 = item["U_INSERT"].Text.Trim();
}
But the columns are coming " " What i am doing wrong here ?