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

[Solved] Client template in Telerik Grid

1 Answer 116 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
erick
Top achievements
Rank 1
erick asked on 02 Jul 2011, 08:36 AM
hi, need a help

have a problem when create Html.ActionLink based on condition 

ie: if username = "manager" then display "granted"
   else display "not granted"

i bumped in ClientTemplate using Ajax Binding

any insight?

thx,
erick

1 Answer, 1 is accepted

Sort by
0
erick
Top achievements
Rank 1
answered on 02 Jul 2011, 05:36 PM
done using this one
.ClientTemplate(Html.ActionLink(
                "<# if (UsersInrole) { #> Remove <# } else { #> Add <#} #>",
                "<# if (UsersInrole) { #>Remove<# } else { #>Add<#} #>",
                new { username = "<#= Username #>", rolename = "<#= RoleName #>" }).ToHtmlString())
my question now, any simpler method???

thx,
erick
Tags
Grid
Asked by
erick
Top achievements
Rank 1
Answers by
erick
Top achievements
Rank 1
Share this question
or