ASP.NET Rows ÊôÐÔ

¶¨ÒåºÍÓ÷¨

Rows ÊôÐÔÓÃÓÚ»ñÈ¡»òÉèÖà ListBox ÖеĿɼûÐÐÊý£¨ÎÞ¹ö¶¯£©¡£

Óï·¨

<asp:ListBox Rows="num" runat="server">
some content
</asp:ListBox>
ÊôÐÔ ÃèÊö
num ¹æ¶¨ ListBox ÖеĿɼûÐÐÊý£¨ÎÞ¹ö¶¯£©¡£

ʵÀý

ÏÂÃæµÄÀý×ÓÉèÖÃÁË ListBox ¿Ø¼þµÄ Rows ÊôÐÔ£º

<form runat="server">
<asp:ListBox id="lb1" Rows="5" runat="server">

  <asp:ListItem Value="Item1" />
  <asp:ListItem Value="Item2" />
  <asp:ListItem Value="Item3" />

  <asp:ListItem Value="Item4" />
  <asp:ListItem Value="Item5" />
</asp:ListBox>
</form>

ʵÀý

ÉèÖà ListBox ¿Ø¼þµÄ Rows ÊôÐÔ