Hi Judy,
Note that the ClientSelectColumn is intended to be used for client-side selection. If you would like to have server-side selection in the Grid I would recommend to use the approach described in the following article.
Moreover, for disabling the button you can use client-side logic. Please examine the following code-snippets that illustrate the approach. Give it a try and let me know how it works for you.
Regards,
Viktor Tachev
Telerik by Progress
Note that the ClientSelectColumn is intended to be used for client-side selection. If you would like to have server-side selection in the Grid I would recommend to use the approach described in the following article.
Moreover, for disabling the button you can use client-side logic. Please examine the following code-snippets that illustrate the approach. Give it a try and let me know how it works for you.
<
telerik:GridTemplateColumn
UniqueName
=
"TemplateColumn"
>
<
ItemTemplate
>
<
asp:Button
ID
=
"Button1"
Text
=
"Click"
runat
=
"server"
/>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
<
ClientSettings
EnablePostBackOnRowClick
=
"true"
>
<
ClientEvents
OnRowCreated
=
"rowCreated"
/>
<
Selecting
AllowRowSelect
=
"true"
/>
</
ClientSettings
>
function
rowCreated(sender, args) {
var
grid = sender;
var
dataItem = args.get_gridDataItem();
var
templateColumn = dataItem.get_cell(
"TemplateColumn"
);
var
button = $telerik.findElement(templateColumn,
"Button1"
);
if
(!dataItem.get_selected()) {
button.disabled =
"disabled"
;
}
}
Regards,
Viktor Tachev
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.