ObjectListViewMode 枚举
定义
注意
The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.
指定对象列表的显示模式。Specifies the display mode of the object list. 此类不能被继承。This class cannot be inherited. 若要了解如何开发 ASP.NET 移动应用,请参阅 Mobile Apps & Sites with ASP.NET (ASP.NET 移动应用和网站)。For information about how to develop ASP.NET mobile applications, see Mobile Apps & Sites with ASP.NET.
public enum class ObjectListViewMode
public enum ObjectListViewMode
[System.Obsolete("The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.")]
public enum ObjectListViewMode
type ObjectListViewMode =
[<System.Obsolete("The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.")>]
type ObjectListViewMode =
Public Enum ObjectListViewMode
- 继承
- 属性
字段
| Commands | 1 | WML 中的命令视图。Command's view in WML. 当包含对象列表的页第一次呈现时,此视图作为默认视图显示。This is the default view displayed when the page containing the object list is rendered for the first time. 它由项的标签字段组成;如果 TableFields 不为空,则由一个表组成,视图的列与表字段对应,视图的行与项对应。It consists of either the label fields of the items, or (when TableFields is not empty) a table with columns corresponding to the table fields and rows corresponding to items. 如果 |
| Details | 2 | 详细信息视图。Details view. 此视图只在 WML 设备上呈现。This view is rendered separately only for WML devices. 它由一个具有 ObjectList 的命令的菜单以及一个显示 |
| List | 0 | 列表视图。List view. 此视图显示项的每个字段,包括标题和值。This view displays each field of the item, including title and value. 在 HTML 中,此视图与 |
注解
显示模式可通过 ViewMode 属性获得。The display mode is available through the ViewMode property. 此枚举允许用户设置控件的当前显示模式 ObjectList 。This enumeration allows the user to set the current display mode of the ObjectList control. 如果具有 ObjectList 项模板,则可以在每个项中放置一个按钮,处理按钮上的 click 事件,并将视图模式设置为 Details 视图,以显示项详细信息。If you have an ObjectList with an item template, you can place a button in each item, handle the click event on the button, and set the view mode to the Details view to show the item details.
备注
在将此枚举设置为或查看之前,必须先选择一个项 Commands Details 。You must first select an item before setting this enumeration to Commands or Details view. 尝试在选择项之前设置枚举会引发异常。An attempt to set the enumeration before selecting an item throws an exception.