0
ASP.NET 2.0无法绑定Visible属性
虽然我尝试,我似乎无法Visible属性数据项属性绑定:
<asp:Panel runat="server" Visible="<%#(bool)Eval("IsBoolean")%>">X</asp:Panel>
我总是这个错误:
Cannot create an object of type 'System.Boolean' from its string representation '"<%#(bool)Eval("IsBoolean")%' for the 'Visible' property.
但这个工程:
<asp:Panel runat="server" Visible="<% true %>">X</asp:Panel>
我在做什么错?我的意思是,除了使用ASP.NET 2.0?
尝试'<%#Convert.ToBoolean(EVAL( “IsBoolean”))== TRUE% >' – VDWWD