In this lesson, you will learn how to make a List View editable. For this purpose, the DemoTask List View will be used.

在本课中,您将学习如何使列表视图可编辑。为此,将使用演示任务列表视图。

Note 注意
Before proceeding, take a moment to review the following lessons.

在继续之前,请花点时间复习以下课程。

  • Set a Many-to-Many Relationship
  • Place an Action in a Different Location
  • Invoke the Model Editor for the MySolution.Module project. Navigate to the Views | MySolution.Module.BusinessObjects | DemoTask_ListView node. It defines the List View that is used for DemoTask objects with the properties to the right. In the AllowEdit property's dropdown list, select "True". When this property is set to "True", the List View is editable.

  • 设置多对多关系

  • 将操作放置在其他位置

  • 调用 MySolution.模块项目的模型编辑器。导航到视图 |My解决方案.模块.业务对象 |DemoTask_ListView节点。它定义用于右侧属性的 DemoTask 对象的列表视图。在"允许编辑"属性的下拉列表中,选择"True"。当此属性设置为"True"时,列表视图是可编辑的。

When List Views are displayed in edit mode, you can apply the NewItemRow functionality of the XtraGrid that displays ListViews in XAF applications. This functionality allows end-users to create new objects directly in a List View without a Detail View. To add this functionality, set the NewItemRowPosition property to Top or Bottom.

当列表视图以编辑模式显示时,您可以应用 XtraGrid 的"新建项目"功能,该功能在 XAF 应用程序中显示 ListViews。此功能允许最终用户直接在列表视图中创建新对象,而无需详细信息视图。要添加此功能,将"新建项目"属性设置为顶部或底部。

Tip 指示
In ASP.NET applications, there are several modes for editing. To set the required mode, use the IModelListViewWeb.InlineEditMode property in the Model Editor invoked for the MySolution.Module.Web project. Various edit modes are illustrated in the List View Edit Modes topic (ASP.NET-Specific Functionality section).

在ASP.NET应用程序中,有多种编辑模式。要设置所需的模式,请使用为 MySolution.module.Web 项目调用的模型编辑器中的 IModelListViewWeb.inlineEditMode 属性。"列表视图编辑模式"主题(ASP.NET特定功能)部分说明了各种编辑模式。

  • Run the WinForms or ASP.NET application and edit one of the DemoTask objects within the List View.

  • 运行 WinForms 或ASP.NET应用程序,并在列表视图中编辑"演示任务"对象之一。

  • To edit one of the DemoTask objects in an ASP.NET application, click Edit() or click New() to create a new Task.
  • 要编辑ASP.NET应用程序中的一个 DemoTask 对象,请单击"编辑(InlineEdit_EditButton)"或单击"新建(InlineEdit_NewButton)"以创建新任务。
  • To edit one of the DemoTask objects in an ASP.NET application, click Edit(InlineEdit_EditButton) or click New(InlineEdit_NewButton) to create a new Task.

  • 要编辑ASP.NET应用程序中的一个 DemoTask 对象,请单击"编辑(InlineEdit_EditButton)"或单击"新建(InlineEdit_NewButton)"以创建新任务。

In a WinForms application, to save the changes made to an object, click the Save () or SaveAndClose () button on the toolbar. To cancel the changes, click the Cancel () button.

在 WinForms 应用程序中,要保存对对象所做的更改,请单击工具栏上的"保存(btn_Save)或保存关闭(btn_SaveClose)按钮。要取消更改,请单击"取消(btn_Cancel)"按钮。

In the ASP.NET application, to save changes, click Update (). To cancel the changes, click Cancel ().

在ASP.NET应用程序中,要保存更改,请单击"更新(btn_Save)。要取消更改,请单击"取消(btn_Cancel)。

Note 注意
You can set the edit mode in code. To do this, apply the DefaultListViewOptionsAttribute attribute to the DemoTask class.

您可以在代码中设置编辑模式。为此,请将"默认列表视图选项属性"属性应用于演示任务类。

To see the changes made in this lesson, invoke the Model Editor for the Main Demo's MainDemo.Module, MainDemo.Module.Win and MainDemo.Module.Web projects. The MainDemo application is installed in %PUBLIC%\Documents\DevExpress Demos 19.2\Components\eXpressApp Framework\MainDemo by default. The ASP.NET version is available online at http://demos.devexpress.com/XAF/MainDemo/

要查看本课中所做的更改,请调用主演示 MainDemo.模块、MainDemo.module.win 和 MainDemo.module.Web 项目的模型编辑器。主演示应用程序安装在%PUBLIC%\Documents\DevExpress Demos 19.2\Components\eXpressApp Framework\MainDemo by default. The ASP.NET version is available online at http://demos.devexpress.com/XAF/MainDemo/

.

Make a List View Editable 使列表视图可编辑的更多相关文章

  1. delphi列表视图组件(TListView)使用方法|实例

    TListView 组件以多种形式显示列表的项目,如详细资料.小图标.大图标等形式表示列表中的项目.    列表视图与用TListBox 组件实现的列表框非常相似.不同的是,列表视图可以让用户选择不同 ...

  2. VS2010/MFC编程入门之二十九(常用控件:列表视图控件List Control 下)

    上一节是关于列表视图控件List Control的上半部分,简单介绍了列表视图控件,其通知消息的处理和有关结构体的定义.本节继续讲解下半部分,包括列表视图控件的创建.CListCtrl类的主要成员函数 ...

  3. MFC常用控件之列表视图控件(List Control)

    近期学习了鸡啄米大神的博客,对其中的一些知识点做了一些自己的总结.不过,博客内容大部分来自鸡啄米.因此,这个博客算是转载博客,只是加了一些我自己的理解而已.若想学习鸡啄米大神的博客总结,请点击连接:h ...

  4. VS2010-MFC(常用控件:列表视图控件List Control 下)

    转自:http://www.jizhuomi.com/software/197.html 上一节是关于列表视图控件List Control的上半部分,简单介绍了列表视图控件,其通知消息的处理和有关结构 ...

  5. SharePoint 2013无代码实现列表视图的时间段动态筛选

    本文介绍两种为列表视图设置时间段筛选器的方法.其中,第一个方法用于SharePoint Server,第二个方法同时还能用于SharePoint Foundation. 方法一:日期筛选器Web部件 ...

  6. Change Field Layout and Visibility in a List View 在列表视图中更改字段布局和可见性

    This lesson will guide you through the steps needed to select columns displayed in the List View. Fo ...

  7. Android列表视图(List View)

    Android列表视图(ListView) ListView是一个显示滚动项列表的示视图组(viewgroup),通过使用适配器(Adapter)把这些列表项自动插入到列表中.适配器比如从一个数组或是 ...

  8. Apply Grouping to List View Data 将分组应用于列表视图数据

    This lesson will teach you how to apply grouping to List View data. For this purpose, you will group ...

  9. Add a Preview to a List View将预览添加到列表视图

    In this lesson, you will learn how to show a preview section in a List View's grid. For this purpose ...

随机推荐

  1. VLAN应用实例

    VLAN 此次内容主要介绍VLAN的Access接口.Trunk接口.Hybird接口的配置实例,以及实际应用. 一.介绍三种接口 1.Access接口 (1)Access接口是交换机上用来连接用户主 ...

  2. 侠梦说pinpoint--界面上的图标之AgetnInfo数据研究

    前言 在启动一个挂载pinpoint的springboot项目的时候,界面上显示成了jboss的图标,所以今天研究了一下这个数据是怎么来的. 我们知道不同图标和服务类型有关,服务不同,图标就不同,这在 ...

  3. luogu P1768 天路 |01分数规划+负环

    题目描述 言归正传,小X的梦中,他在西藏开了一家大型旅游公司,现在,他要为西藏的各个景点设计一组铁路线.但是,小X发现,来旅游的游客都很挑剔,他们乘火车在各个景点间游览,景点的趣味当然是不用说啦,关键 ...

  4. 数据挖掘算法(三)--logistic回归

    数据挖掘算法学习笔记汇总 数据挖掘算法(一)–K近邻算法 (KNN) 数据挖掘算法(二)–决策树 数据挖掘算法(三)–logistic回归 在介绍logistic回归之前先复习几个基础知识点,有助于后 ...

  5. unity3d 动态添加地面贴图 草地

    TerrainData.splatPrototypes = ]{ new SplatPrototype() { texture=Caodi, //Texture2D的贴图 normalMap=null ...

  6. 使用iCamera 白平衡调试小结 CC1603@AR0134

    使用iCamera 白平衡调试小结 CC1603@AR0134 iCamera有强大的各种摄像头调试功能 之前演示过的有:曝光.增益.各种寄存器测试.RAW.yuv输出 今天测试下白平衡功能 绝大多数 ...

  7. font-family与font-face的区别

    font-family:指定字体 设置后,电脑上无该字体时,观看网页不能显示该字体效果, 针对中文版操作系统,为保证网页效果,通常只指定:宋体.黑体.微软雅黑等系统上默认自带的字体. font-fac ...

  8. 超简单!asp.net core前后端分离项目使用gitlab-ci持续集成到IIS

    现在好多使用gitlab-ci的持续集成的教程,大部分都是发布到linux系统上的,但是目前还是有很大一部分企业使用的都是windows系统使用IIS在部署.NET应用程序.这里写一下如何使用gitl ...

  9. LNMP环境搭建(<=PHP7.2)

    目录 准备工作 安装wget 安装net-tools 安装vim 配置显示行号 关闭防火墙 安装Nginx 安装依赖 编译安装Nginx 配置环境变量 Systemd管理 安装MySQL 安装依赖 下 ...

  10. 搞清楚Spring Cloud架构原理的这4个点,轻松应对面试

    前言 现在分布式系统基本上都是标配了,如果你现在还在玩儿单机,没有接触过这些东西的话,权当是为你打开一扇新的大门吧. 大的单体项目 以前我们做单机系统的时候,所有的代码都在一个项目里面,只是不同的模块 ...