Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
435
Child grid showing link calling MVC controller action
posted

I have a hierarchical grid, in the child grid, I am trying to show unbound columns with link which will call some controller action methods. I was trying to play with ActionLink as below, but seems like it doesn't like my code.

childcolumn.Unbound("Address").Template(@Html.ActionLink("Address", "Address/Getddress"));

Above .ActionLink returns MVCHtmlString and Template only takes string, so I tried doing ToString, but still something is wrong.

Any help would be appreciated.

 

 

 

Parents
No Data
Reply
  • 435
    Verified Answer
    posted

    I did it as below:

    childcolumn.Unbound("ColumnName").HeaderText("").Template("<a href='#' onClick='linkClick(this);'>Some Value</a>")

Children
No Data