Hi,
I need to click on some link in my rad grid.
I have 2 like per row.
on each link im using the following code till i get an answer:
<
telerik:GridHyperLinkColumn
UniqueName
=
"LinkRpt"
DataTextFormatString
=
"S/N {0} "
DataTextField
=
"UsrSN"
DataNavigateUrlFields
=
"CaseID"
DataNavigateUrlFormatString
=
"~/Site/mypage.aspx?var={0}"
HeaderText
=
"Repport link"
>
</
telerik:GridHyperLinkColumn
>
As you can see im using " Request.QueryString["var"] ".
But i want the var to be in Session. Because this 'var' is a sensitive data.
I know how to put things in session. Session["field1"] = "value1";
But i can't do that with a GridHyperLinkColum because there is no OnClick event.
Its the same for the GridButtonColumn.
So i guess i have to use GridTemplateColumn with a RadButtonin it.
<
telerik:GridTemplateColumn
>
<
ItemTemplate
>
<
telerik:RadButton
ID
=
"RadButton1"
runat
=
"server"
Text
=
"See Repport."
OnClick
=
"RadButton1_Click"
>
</
telerik:RadButton
>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
In this RadButton1_Click, what should i do to get the CaseID of the row clicked.
How do i navigate to my "~/Site/mypage.aspx" ?
if i use Javascript:
function
OnClientClicking(button, args) {
window.location = button.get_navigateUrl();
args.set_cancel(
true
);
}
with the OnClientClicking how do i set things in session ?
Any suggestion will be appreciated.
Regards,
Pierre.