hi
I put below code in gridview:
<asp:Label ID="Label14T" runat="server" Text='<%# Eval("GroupName")%>' CssClass="ViewNG"
Visible = '<%#Eval("GroupName").ToString() == "فروشندگان ملک"||"مستاجرین" ? true : false %>'></asp:Label>
but below error happen:
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: CS0019: Operator '||' cannot be applied to operands of type 'bool' and 'string'
Source Error:
|
Line 437:
Line 438:
Line 439: <asp:Label ID="Label14T" runat="server" Text='<%# Eval("GroupName")%>' CssClass="ViewNG"
Line 440: Visible = '<%#Eval("GroupName").ToString() == "فروشندگان ملک"||"مستاجرین" ? true : false %>'></asp:Label>
Line 441: </ItemTemplate>
|