2014年好久没有更新Blog了,工作调换了,很少用XAF,但还是很关注XAF的发展和学习,对中国的中小企业数据管理软件开发真的太实用了!!

功能比较简单,但很实用,直接上图和代码!

ListView處於ListViewAndDetailView編輯模式

using System;
using System.Linq;
using System.Text;
using DevExpress.ExpressApp;
using DevExpress.Data.Filtering;
using System.Collections.Generic;
using DevExpress.Persistent.Base;
using DevExpress.ExpressApp.Utils;
using DevExpress.ExpressApp.Layout;
using DevExpress.ExpressApp.Actions;
using DevExpress.ExpressApp.Editors;
using DevExpress.ExpressApp.Templates;
using DevExpress.Persistent.Validation;
using DevExpress.ExpressApp.SystemModule;
using DevExpress.ExpressApp.Model.NodeGenerators;
using DevExpress.Xpo;
using DevExpress.XtraEditors;
using DevExpress.ExpressApp.Win.Templates;namespace SimpleProjectManager.Module.Controllers
{// For more typical usage scenarios, be sure to check out http://documentation.devexpress.com/#Xaf/clsDevExpressExpressAppViewControllertopic.public partial class EditerPlusieursLignesListViewController : ViewController<ListView>{public EditerPlusieursLignesListViewController(){InitializeComponent();RegisterActions(components);// Target required Views (via the TargetXXX properties) and create their Actions.
        }protected override void OnActivated(){base.OnActivated();if (View == null)return;if(((ListView)View).EditView == null)return;if( ((ListView)View).EditView.Items==null)return;foreach (ViewItem item in ((ListView)View).EditView.Items){item.ControlCreated += item_ControlCreated;}}void item_ControlCreated(object sender, EventArgs e){ViewItem item = (ViewItem)sender;if (item.Control.GetType() == typeof(NestedFrameTemplate)) return;((BaseEdit)item.Control).EditValueChanged += (sender2, e2) =>{if (View != null && View.SelectedObjects.Count > 1){foreach (XPBaseObject xpo in View.SelectedObjects){xpo.SetMemberValue(item.Id, ((BaseEdit)sender2).EditValue);}}};}       }
}

转载于:https://www.cnblogs.com/Tonyyang/p/4082914.html

[原] XAF How to Edit multiple objects in a ListViewAndDetailView相关推荐

  1. [原] XAF 添加日期筛选下拉选择

    1.ListView 添加日期筛选下拉选择,选择指定,可指定日期范围 2.Code using DevExpress.Data.Filtering; using DevExpress.ExpressA ...

  2. [原] XAF How to implement a custom attribute to customize the Application Model

    http://www.devexpress.com/Support/Center/Example/Details/E1679 转载于:https://www.cnblogs.com/Tonyyang/ ...

  3. Co-Fusion: Real-time Segmentation, Tracking and Fusion of Multiple Objects

    这篇文章其实就是几篇文章凑在了一起. fusion的部分用的是 ElasticFusion: Dense SLAM without a pose graph 这篇文章实现了local loop clo ...

  4. 《Ray Tracing in One Weekend》——Chapter 5: Surface normals and multiple objects

    总结<Ray Tracing in One Weekend>全文 第一部分:学习总结 问题十四:怎么可视化球的法向量 问题十七:怎么用ray tracing画多个球? 中途又补充了点C++ ...

  5. [转]使用Cool Edit Pro和Adobe Audition消除原唱

    用Cool Edit Pro消除原唱,方法实际上可以说很简单,然而要想把它做的很完美还是得下点功夫. 我这里说的"消原唱"只是Cool Edit Pro菜单中的一个独立功能,选择并 ...

  6. D23:Multiple of 3 Or 5(3或5的倍数,翻译+题解)

    原题:OpenJudge - 23:Multiple of 3 Or 5 翻译: 描述:求[1,N]里有多少个整数是3或5的倍数: 输入:一个不超过100000的正整数N: 输出:一个整数. 代码: ...

  7. komodo edit 支持java么_Komodo Edit for Mac(多语言集成开发环境)

    原标题:Komodo Edit for Mac(多语言集成开发环境) Komodo Edit for mac是一个跨平台支持多种程序语言的Integrated Development Environm ...

  8. BDB 入门篇 第5章 Saving and Retrieving Objects 保存和检索对象

    第5章 Saving and Retrieving Objects 保存和检索对象 要将对象存储在EntityStore中,您必须对类进行相应的注解,然后将其存储 PrimaryIndex.put() ...

  9. 【转】经济计量学软件包Eviews快速使用

    Eviews软件使用 经济计量学软件包Eviews快速使用 袁建文 整理编写 内容导引: 一.启动软件包 附录:经济计量学软件包Eviews简介 二.创建工作文件 一.经济计量学软件包的主要功能 三. ...

最新文章

  1. Design Pattern - Adapter(C#)
  2. 关于IFRAME的一些小应用
  3. mysql 代码执行时间_mysql 显示SQL语句执行时间的代码
  4. callablestatement.setstring会不会将字符串trim_Java String:重要到别人只能当老二的字符串类
  5. 【CodeForces - 789D】Weird journey(思维,图的性质,tricks,有坑)
  6. python3纵向输出字符串_笔记||Python3之字符串格式化输出
  7. spring整合ehcache
  8. 【以前的空间】vijos 1720 阿狸的打字机
  9. 精通CSS:高级Web标准解决方案(第2版)--前言
  10. kotlin_Kotlin
  11. 凸优化第二章凸集 2.6对偶锥与广义不等式
  12. UG NX二次开发(C#)-分析-测量体对象的体积
  13. SAP中的输入历史记录设定
  14. 硬盘服务器与硬盘阵列,磁盘阵列和硬盘的区别是什么
  15. C语言经典案例——第六章 字符串
  16. python数据类型的转化和获取
  17. Conflux一周年 | 25分钟 VS 以太坊7个月,伍爷の硬核庆生
  18. 选择勤哲Excel服务器做企业管理系统ERP的经验之谈
  19. JVM内置函数intrinsics简介
  20. 行业报告免费下载-干货!68份营销行业报告分享

热门文章

  1. 爬虫 | 正则表达式提取腾讯教育新闻链接及图片链接
  2. 初学者编写python用什么软件好_初学者编写python用什么软件
  3. 计算机中iis6.0配置步骤,Win2003 IIS6.0 安装方法 图文详细教程
  4. python与pyqt5_【Python开发】PyQt5应用与实践
  5. 四、HTTP响应报文格式
  6. C++知识点10——函数指针
  7. css数字发光,每日CSS_发光文本效果
  8. int类型年月怎么区间查询_LeetCode 力扣官方题解 | 57.插入区间
  9. python跟java 效率_Python与Java:哪个更好,如何选择?
  10. android简单app实例_Android安卓小项目实战视频教程集锦