📄 objectlist.aspx
字号:
<%@ Page Inherits="System.Web.UI.MobileControls.MobilePage" Language="C#" %>
<html>
<head>
<title>Object List</title>
</head>
<body>
<script language="C#" runat=server>
void Page_Load( object s, System.EventArgs e)
{
if (!IsPostBack)
{
ArrayList colArrayList = new ArrayList();
colArrayList.Add("Star Wars");
colArrayList.Add("Gone with the Wind");
colArrayList.Add("Citizen Kane");
lstMovies.DataSource = colArrayList;
lstMovies.DataBind();
}
}
void ObjectList_ItemCommand( object s, ObjectListCommandEventArgs e ) {
if ( e.CommandName == "Buy" )
{
ActiveForm = frmBuyTicket;
}
else
{
ActiveForm = frmShowDesc;
}
}
</Script>
<Mobile:Form id="displayMovies" runat="Server">
<Mobile:ObjectList
ID="lstMovies"
OnItemCommand="ObjectList_ItemCommand"
Runat="Server">
<Command Name="Buy" Text="Buy" />
<Command Name="Desc" Text="Desc" />
</Mobile:ObjectList>
</Mobile:Form>
<Mobile:Form id="frmShowDesc" runat="Server">
<b>Great Movie!</b>
</Mobile:Form>
<Mobile:Form id="frmBuyTicket" runat="Server">
<b>Buy Ticket!</b>
</Mobile:Form>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -