I need to show a command button conditionally based on data in the grid. I'm using the example in the link below but it's not working.
If I leave off the parentheses in the visible property then the javascript call never gets made. If I add them, the javascript call does get made but the data parameter is undefined.
I am using Core and the Razor syntax, not MVC and the HTML helpers as the example shows but I would assume the same concept should work. Any ideas on why this is not working?
ASP.NET MVC Data Grid Component Show Command Buttons Conditionally | Telerik UI for ASP.NET MVC
<commands>
<column-command name="questionanswers" click="goToQuestionAnswers" class-name="link-button" text="Answers" visible="isAnswerButtonVisible()"></column-command>
<column-command name="edit" class-name="link-button" icon-class="k-no-icon"></column-command>
<column-command name="destroy" class-name="link-button" icon-class="k-no-icon" text="Delete"></column-command>
</commands>
function isAnswerButtonVisible(data) {
return data.QuestionType !== "TrueFalse";
}