hi
I used gridview and write below code on gridview:
<div id="Griddes1" runat="server" class="Griddes1" Visible='<%#Eval("PType").ToString() == "فيلم مستند" ? true : false %>'>
it make div's visibility according to [Ptype] column in database if it was "فیلم مستند" it will be true...
now I want it checked if in Ptype column="فیلم مستند" Or "سریال" it make visible=true so I wrote below code:
<div id="Griddes1" runat="server" class="Griddes1" Visible='<%#Eval("PType").ToString() == "فيلم مستند"||"سریال" ? true : false %>'>
but it makes error:
Server Error in '/' Application.
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 269: </div>
Line 270: </div>
Line 271: <div id="Griddes1" runat="server" class="Griddes1" Visible='<%#Eval("PType").ToString() == "فيلم مستند"||"سریال" ? true : false %>'>
Line 272: <div id="lblnameGO2">
Line 273:
|
Best Regards
Neda