同桌上课用手指进去了好爽_欧美丰满熟妇xxⅹⅹ性大i_成人av天天日天天拍拍_猛男gay帅男gay男男同志_欧美va天堂在线观看_人妻无码av中文系列三里桃花_亚欧免费无码在线观看_久久久精品国产亚洲av水_日韩在线免费看污污污_2021无码专区人妻系列日韩

首頁 優(yōu)化推廣 ASPX頁面寫IF語句怎么寫(IF判斷)

ASPX頁面寫IF語句怎么寫(IF判斷)

來源: | 時(shí)間:2011/2/19 6:19:00 |

用 <%內(nèi)嵌代碼%>
比如  :
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>內(nèi)嵌代碼的用法</title>
</head>
<body>
<form id="form1" runat="server">
<%if(DateTime.Now.Hour<12)%>
上午好!
<%else%>
下午好!
</form>
</body>
</html>

 

 

問 :
<table   border="1"   style="width:   545px;   height:   188px">  
                                          <tr>  
                                                  <td>  
                                                          &nbsp;<asp:Label   ID="BODYLabel"   runat="server"   Text= <%#   Eval("BODY")   %> ></asp:Label></td>  
                                          </tr>  
                                </table>  
                       
                如果     RE_BODY不等于空那么顯示下面的回復(fù)內(nèi)容,     //   這句話怎么寫?  
   
   
   
                                  <table   border="1"   style="width:   543px;   height:   143px">  
                                      <tr>  
                                                  <td>  
                                                          &nbsp;<asp:Label   ID="RE_BODYLabel"   runat="server"   Text= <%#   Eval("RE_BODY")   %> ></asp:Label></td>  
                                          </tr>  
                                  </table>  
 

回答:

ASP.NET推薦是這樣寫:  
   
   
  <table   border="1"   style="width:   545px;   height:   188px">  
                                          <tr>  
                                                  <td>  
                                                          &nbsp;<asp:Label   ID="BODYLabel"   runat="server"   Text= <%#   Eval("BODY")   %> ></asp:Label></td>  
                                          </tr>  
                                </table>  
   
   
                                  <table   border="1"   style="width:   543px;   height:   143px"   runat="server"   Visibly= <%#   Eval("RE_BODY")   !=   null   %> >  
                                      <tr>  
                                                &n

服務(wù)熱線

153 8323 9821

功能和特性

價(jià)格和優(yōu)惠

網(wǎng)站和維護(hù)

推廣和優(yōu)化

微信服務(wù)號