защищенный недействительный onrow (отправитель объекта, GridViewRowEventArgs e)

м .aspx я ищу, чтобы добавить оператор If на основе значения, полученного из привязки. Я пробовал следующее:

<% if(bool.Parse(Eval("IsLinkable") as string)){ %>                    
        monkeys!!!!!!
        (please be aware there will be no monkeys, 
        this is only for humour purposes)
 <%} %>

IsLinkable - это бул, пришедший из Binder. Я получаю следующую ошибку:

InvalidOperationException
Databinding methods such as Eval(), XPath(), and Bind() can only
be used in the context of a databound control.

Ответы на вопрос(11)

Ваш ответ на вопрос